DreamN
Smart Contract Audit Report
Audit Summary
DreamN is a new BEP-20 token on the Binance Smart Chain.
For this audit, we reviewed the project team's DreamN contract at 0x7fCa026d67FEec1C7Cf88ab866D2678dFB2B5243 on the Binance Smart Chain Mainnet.
Audit Findings
Please ensure trust in the team prior to investing as they have notable control in the ecosystem.
Date: May 6th, 2022.
Contract Overview
Ownership Controls:
- The total supply of the token is set to 20 million $DreamN [20,000,000].
- No mint or burn functions are accessible, though the circulating supply can be decreased by sending tokens to the 0x..dead address.
- At the time of writing this report, 100% of the total supply belongs to the team's Marketing wallet.
- Trading must be manually enabled by the owner in order for all trading to successfully take place on the platform. Only whitelisted users can transfer tokens while trading is disabled.
- Once trading is enabled, it can never be disabled.
- There is a fee on all transfers where neither the sender nor the recipient has been added to the whitelist.
- The AntiSniper tax is enabled upon deployment. While enabled, all transfers for non-whitelisted users will be taxed at a 99% rate.
- The Buy fee percentage will be charged when a user is buying tokens from a CEX or AMM Pair address set by the team.
- The Sell fee percentage will be charged when a user is selling tokens to an AMM Pair address set by the team.
- The standard transfer fee percentage will be charged if the transaction does not involve a CEX or AMM Pair address.
- The fee will not be charged when selling tokens to a CEX address.
- The tokens collected from the fee are stored in the contract address. The tokens are swapped for BNB for the purpose of funding team wallets when the following conditions are met:
- The automatic token swapping functionality is enabled by the team.
- The threshold number of tokens (determined by the owner) in the contract address has been reached.
- The caller is initiating a sell transaction.
- The BNB received through this process is split between the team's Rewards wallet, Marketing wallet, and Development wallet.
- As the contract is deployed with Solidity v0.8.13 it is protected from overflows/underflows.
- The contract complies with the BEP-20 token standard.
- The owner can set the Buy fee up to 10% and the Sell fee up to 20% at any time.
- The owner can set the standard transfer fee to any percentage at any time.
- The owner can permanently disable the AntiSniper fee at any time.
- The owner can add/remove accounts from the fee whitelist at any time.
- The owner can add/remove addresses as a CEX or AMM Pair address at any time.
- The owner can update the percentage of BNB that gets allocated to each fund (Rewards, Marketing, Development) at any time.
- The owner can update the team's Rewards wallet, Marketing wallet, and Development wallet at any time.
- The owner can enable/disable the automatic token swapping functionality at any time.
- The owner can update the threshold number of tokens that triggers the automatic token swapping functionality to any value at any time.
- The owner can manually trigger the token swapping functionality at any time.
- The owner can transfer any number of tokens from the contract to the 0x..dead address at any time.
- The owner can set the amount of gas used for sending BNB to team wallets to any value between 21,000 and 50,000.
Audit Results
| Vulnerability Category | Notes | Result |
|---|---|---|
| Arbitrary Storage Write | N/A | PASS |
| Arbitrary Jump | N/A | PASS |
| Centralization of Control | The owner can set the standard transfer fee to any percentage. | WARNING |
| Compiler Issues | N/A | PASS |
| Delegate Call to Untrusted Contract | N/A | PASS |
| Dependence on Predictable Variables | N/A | PASS |
| Ether/Token Theft | N/A | PASS |
| Flash Loans | N/A | PASS |
| Front Running | The automatic token swapping functionality may be susceptible to front-running; The team must monitor and if suspicious activity is detected, the team should lower the swapThreshold value or disable this system altogether. | PASS |
| Improper Events | N/A | PASS |
| Improper Authorization Scheme | N/A | PASS |
| Integer Over/Underflow | N/A | PASS |
| Logical Issues | N/A | PASS |
| Oracle Issues | N/A | PASS |
| Outdated Compiler Version | N/A | PASS |
| Race Conditions | N/A | PASS |
| Reentrancy | N/A | PASS |
| Signature Issues | N/A | PASS |
| Unbounded Loops | N/A | PASS |
| Unused Code | N/A | PASS |
| Overall Contract Safety | PASS |
Inheritance Chart
Function Graph

Functions Overview
($) = payable function
# = non-constant function
Int = Internal
Ext = External
Pub = Public
+ [Int] IBEP20
- [Ext] totalSupply
- [Ext] decimals
- [Ext] symbol
- [Ext] name
- [Ext] getOwner
- [Ext] balanceOf
- [Ext] transfer #
- [Ext] allowance
- [Ext] approve #
- [Ext] transferFrom #
+ Ownable
- [Pub] #
- [Pub] transferOwnership #
- modifiers: onlyOwner
- [Int] owner
+ BEP20 (IBEP20, Ownable)
- [Pub] #
- modifiers: Ownable
- [Pub] getOwner
- [Pub] decimals
- [Ext] symbol
- [Ext] name
- [Ext] totalSupply
- [Pub] balanceOf
- [Ext] transfer #
- [Ext] allowance
- [Ext] approve #
- [Ext] transferFrom #
- [Pub] increaseAllowance #
- [Pub] decreaseAllowance #
- [Int] _transfer #
- [Int] _approve #
+ [Int] IDexFactory
- [Ext] createPair #
+ [Int] IDexRouter
- [Ext] factory
- [Ext] WETH
- [Ext] swapExactTokensForETH #
+ DreamN (BEP20)
- [Pub] #
- modifiers: BEP20
- [Int] _transfer #
- [Ext] ($)
- [Prv] _takeTax #
- [Prv] _getTotalTax
- [Prv] _shouldSwapBack
- [Prv] _swapBack #
- modifiers: swapping
- [Ext] enableTrading #
- modifiers: onlyOwner
- [Ext] removeSniperTax #
- modifiers: onlyOwner
- [Ext] triggerSwapBack #
- modifiers: onlyOwner
- [Ext] burnFromStorage #
- modifiers: onlyOwner
- [Ext] recoverBNB #
- modifiers: onlyOwner
- [Ext] recoverBEP20 #
- modifiers: onlyOwner
- [Ext] setIsWhitelisted #
- modifiers: onlyOwner
- [Ext] setIsCEX #
- modifiers: onlyOwner
- [Ext] setIsMarketMaker #
- modifiers: onlyOwner
- [Ext] setTaxes #
- modifiers: onlyOwner
- [Ext] setShares #
- modifiers: onlyOwner
- [Ext] setSwapBackSettings #
- modifiers: onlyOwner
- [Ext] setTransferGas #
- modifiers: onlyOwner
- [Ext] setDevelopmentWallet #
- modifiers: onlyOwner
- [Ext] setMarketingWallet #
- modifiers: onlyOwner
- [Ext] setRewardWallet #
- modifiers: onlyOwner About SourceHat
SourceHat has quickly grown to have one of the most experienced and well-equipped smart contract auditing teams in the industry. Our team has conducted 1800+ solidity smart contract audits covering all major project types and protocols, securing a total of over $50 billion U.S. dollars in on-chain value!
Our firm is well-reputed in the community and is trusted as a top smart contract auditing company for the review of solidity code, no matter how complex. Our team of experienced solidity smart contract auditors performs audits for tokens, NFTs, crowdsales, marketplaces, gambling games, financial protocols, and more!
Contact us today to get a free quote for a smart contract audit of your project!
What is a SourceHat Audit?
Typically, a smart contract audit is a comprehensive review process designed to discover logical errors, security vulnerabilities, and optimization opportunities within code. A SourceHat Audit takes this a step further by verifying economic logic to ensure the stability of smart contracts and highlighting privileged functionality to create a report that is easy to understand for developers and community members alike.
How Do I Interpret the Findings?
Each of our Findings will be labeled with a Severity level. We always recommend the team resolve High, Medium, and Low severity findings prior to deploying the code to the mainnet. Here is a breakdown on what each Severity level means for the project:
- High severity indicates that the issue puts a large number of users' funds at risk and has a high probability of exploitation, or the smart contract contains serious logical issues which can prevent the code from operating as intended.
- Medium severity issues are those which place at least some users' funds at risk and has a medium to high probability of exploitation.
- Low severity issues have a relatively minor risk association; these issues have a low probability of occurring or may have a minimal impact.
- Informational issues pose no immediate risk, but inform the project team of opportunities for gas optimizations and following smart contract security best practices.