Hollywood Inu
Smart Contract Audit Report
Audit Summary
Hollywood Inu is a new ERC-20 token on Ethereum that provides automatic liquidity adds.
For this audit, we reviewed the project team's HollywoodInu contract at 0x3b6fd94921110BA497A0C754819fB7e647036633 on the Ethereum Mainnet.
Audit Findings
Please ensure trust in the team prior to investing as they have substantial control in the ecosystem.
Date: March 15th, 2022.Finding #1 - HollywoodInu - Low
Description: The token burning functionality from the Liquidity pool is susceptible to front running.
Risk/Impact: Miners can benefit from the price impact that this functionality will have on the token.
Recommendation: The team must monitor and if suspicious activity is detected, the team should disable this functionality.Finding #2 - HollywoodInu - Informational
Description: Two functions are declared public, but are never called internally.Recommendation: We recommend declaring these functions external for additional gas savings on each call.setAutomatedMarketMakerPair, isExcludedFromFees
Finding #3 - HollywoodInu - Informational
Description: ThemanualBurnFrequency
state variable can never be modified, but is not declared constant.
Recommendation: This state variable can be declared constant for additional gas savings on each call.Finding #4 - HollywoodInu - Informational
Description: Although the SafeMath library is utilized, the contract is deployed with Solidity v0.8.10 which has built-in overflow checks.
Recommendation: SafeMath could be safely removed to reduce contract size and deployment costs.
Contract Overview
Ownership Controls:
- The total supply of the token is set to 1 billion $HWI [1,000,000,000].
- No mint or burn functions exist, though the circulating supply can be decreased by sending tokens to the 0x..dead address.
- At the time of writing this report, there are 1,051 total token holders. The token allocation is as follows:
- 7.14% of the total supply is in Uniswap liquidity.
- Of that liquidity, 65.3% of the LP tokens are stored in the SNAP! Liquidity Pools contract and will vest to the team on June 5th, 2022
- 34.69% of the LP tokens have been sent to the 0x..dead address.
- 2.99% of the total supply has been sent to the 0x..dead address.
- The next five holders own a cumulative 8.76% of the total supply.
- The contract enforces a transfer delay which prevents a transfer from occurring if the user is attempting to buy from Uniswap more than one time per block.
- The contract enforces a maximum wallet amount which prevents a transaction from occurring if the recipient's balance will exceed the limit number of tokens (determined by the owner) after the transaction takes place.
- The contract enforces a maximum transaction amount which imposes a limit to the number of tokens that can be transferred during any given transaction via Uniswap.
- There is a Liquidity fee, Marketing fee, and Dev fee on all transfers via Uniswap where neither the sender nor the recipient is excluded from fees. A separate fee structure can be set by the team to apply different fee percentages depending on whether the user is buying or selling during the transfer.
- The fees charged during transfers are stored in the contract address. The tokens are swapped for ETH for the purpose of funding Uniswap liquidity when the following conditions are met:
- The automatic liquidity add functionality is enabled by the team.
- The threshold number of tokens in the contract address (determined by the owner) has been reached.
- The contract is not currently performing an automatic liquidity add.
- The caller is not performing a buy transaction via Uniswap.
- Both the sender and the recipient are not excluded from fees.
- Liquidity-adds are automatically performed by selling the tokens collected as fees, pairing the received ETH with the token, and adding it as liquidity to the ETH pair.
- The LP tokens received through this process are sent to the 0x..dead address.
- The tokens collected from the Marketing and Dev fee are swapped for ETH and sent to the team's Marketing wallet and Dev wallet respectively.
- A percentage of tokens (determined by the owner) in the Uniswap Pair address will automatically be sent to the 0x..dead address on all sell transfers via Uniswap as long as the wait time has passed since this functionality has previously occurred.
- As the contract is deployed with Solidity v0.8.10, it is protected from overflows/underflows.
- The contract complies with the ERC-20 token standard.
- The owner can modify the Liquidity fee, Marketing fee, and Dev fee for both the buy and sell fee structures. The total fee percentages combined must not exceed 20% when buying and 25% when selling.
- The owner can exclude and include accounts from transfer fees.
- The owner can update the maximum wallet amount to any value greater than 5 million tokens.
- The owner can update the maximum transaction amount to any value greater than 100,000 tokens.
- The owner can exclude/include accounts from the maximum wallet amount and maximum transaction amount restrictions at any time.
- The owner can enable/disable the automatic swapping functionality at any time.
- The owner can update the threshold number of tokens needed to trigger the automatic swapping functionality to any value between 10,000 and 5 million tokens.
- The owner can update the percentage of tokens that are automatically sent to the 0x..dead address from the Uniswap Pair address on sells via Uniswap to any percentage between 0% and 10%.
- The owner can update the amount of time that must pass before the above functionality can reoccur to any time greater than 10 minutes (in seconds).
- The owner can manually burn up to 10% of the Uniswap Pair token balance every 30 minutes. This functionality is susceptible to front running by miners.
- The owner can disable the transfer delay restriction at any time.
- The owner can update the team's Marketing wallet and Dev wallet to any addresses at any time.
- The owner can update the Automated Market Maker Pair contract address at any time.
Audit Results
Vulnerability Category | Notes | Result |
---|---|---|
Arbitrary Jump/Storage Write | N/A | PASS |
Centralization of Control | 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 token burning functionality from the Liquidity pool is susceptible to front running. The team must monitor and if suspicious activity is detected, the team should disable this functionality. | WARNING |
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
+ Context
- [Int] _msgSender
- [Int] _msgData
+ Ownable (Context)
- [Pub] #
- [Pub] owner
- [Pub] renounceOwnership #
- modifiers: onlyOwner
- [Pub] transferOwnership #
- modifiers: onlyOwner
- [Int] _transferOwnership #
+ [Int] IERC20
- [Ext] totalSupply
- [Ext] balanceOf
- [Ext] transfer #
- [Ext] allowance
- [Ext] approve #
- [Ext] transferFrom #
+ [Int] IERC20Metadata (IERC20)
- [Ext] name
- [Ext] symbol
- [Ext] decimals
+ ERC20 (Context, IERC20, IERC20Metadata)
- [Pub] #
- [Pub] name
- [Pub] symbol
- [Pub] decimals
- [Pub] totalSupply
- [Pub] balanceOf
- [Pub] transfer #
- [Pub] allowance
- [Pub] approve #
- [Pub] transferFrom #
- [Pub] increaseAllowance #
- [Pub] decreaseAllowance #
- [Int] _transfer #
- [Int] _mint #
- [Int] _burn #
- [Int] _approve #
- [Int] _beforeTokenTransfer #
- [Int] _afterTokenTransfer #
+ [Lib] SafeMath
- [Int] tryAdd
- [Int] trySub
- [Int] tryMul
- [Int] tryDiv
- [Int] tryMod
- [Int] add
- [Int] sub
- [Int] mul
- [Int] div
- [Int] mod
- [Int] sub
- [Int] div
- [Int] mod
+ [Int] IUniswapV2Factory
- [Ext] feeTo
- [Ext] feeToSetter
- [Ext] getPair
- [Ext] allPairs
- [Ext] allPairsLength
- [Ext] createPair #
- [Ext] setFeeTo #
- [Ext] setFeeToSetter #
+ [Int] IUniswapV2Pair
- [Ext] name
- [Ext] symbol
- [Ext] decimals
- [Ext] totalSupply
- [Ext] balanceOf
- [Ext] allowance
- [Ext] approve #
- [Ext] transfer #
- [Ext] transferFrom #
- [Ext] DOMAIN_SEPARATOR
- [Ext] PERMIT_TYPEHASH
- [Ext] nonces
- [Ext] permit #
- [Ext] MINIMUM_LIQUIDITY
- [Ext] factory
- [Ext] token0
- [Ext] token1
- [Ext] getReserves
- [Ext] price0CumulativeLast
- [Ext] price1CumulativeLast
- [Ext] kLast
- [Ext] mint #
- [Ext] burn #
- [Ext] swap #
- [Ext] skim #
- [Ext] sync #
- [Ext] initialize #
+ [Int] IUniswapV2Router02
- [Ext] factory
- [Ext] WETH
- [Ext] addLiquidity #
- [Ext] addLiquidityETH ($)
- [Ext] swapExactTokensForTokensSupportingFeeOnTransferTokens #
- [Ext] swapExactETHForTokensSupportingFeeOnTransferTokens ($)
- [Ext] swapExactTokensForETHSupportingFeeOnTransferTokens #
+ HollywoodInu (ERC20, Ownable)
- [Pub] #
- modifiers: ERC20
- [Ext] ($)
- [Ext] enableTrading #
- modifiers: onlyOwner
- [Ext] removeLimits #
- modifiers: onlyOwner
- [Ext] disableTransferDelay #
- modifiers: onlyOwner
- [Ext] updateSwapTokensAtAmount #
- modifiers: onlyOwner
- [Ext] updateMaxTxnAmount #
- modifiers: onlyOwner
- [Ext] updateMaxWalletAmount #
- modifiers: onlyOwner
- [Pub] excludeFromMaxTransaction #
- modifiers: onlyOwner
- [Ext] updateSwapEnabled #
- modifiers: onlyOwner
- [Ext] updateBuyFees #
- modifiers: onlyOwner
- [Ext] updateSellFees #
- modifiers: onlyOwner
- [Pub] excludeFromFees #
- modifiers: onlyOwner
- [Pub] setAutomatedMarketMakerPair #
- modifiers: onlyOwner
- [Prv] _setAutomatedMarketMakerPair #
- [Ext] updateMarketingWallet #
- modifiers: onlyOwner
- [Ext] updateDevWallet #
- modifiers: onlyOwner
- [Pub] isExcludedFromFees
- [Int] _transfer #
- [Prv] swapTokensForEth #
- [Prv] addLiquidity #
- [Prv] swapBack #
- [Ext] setAutoLPBurnSettings #
- modifiers: onlyOwner
- [Int] autoBurnLiquidityPairTokens #
- [Ext] manualBurnLiquidityPairTokens #
- 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.