Safe The Humanity (STH) - Audit Report
Safe The Humanity (STH) is a new DeFi project on the Binance Smart Chain that claims to be a next-generation, community-oriented, static rewards and automatic liquidity protocol with a unique focus on charity donations using governance voting.
Notes on the Contract:
Audit Findings Summary
- Safe The Humanity's code implements and builds upon the fee-redistribution features pioneered by Reflect Finance.
- The total supply of the token is set to one quadrillion STH [1,000,000,000,000,000].
- No minting or burn functions are present; and holders are not allowed to send tokens to the burn address. Tokens can be sent to the burn address upon deployment. If the owner does not exclude the burn address after deploying, it will participate in the reward distribution (as a regular holder) and increase proportionally to the rewards it receives. This is often used as a deflationary mechanism.
- There is a 'taxfee' and a 'liquidity fee' on all transactions for any "non-excluded" address that participates in a transfer. The owner has the ability to modify the these fees at any time. The tax fee may range from 0.0% to 1.0%; while the liquidity fee may range from 0.0% to 3.0%.
- The 'tax fee' is redistributed to existing token holders instantly and automatically at the time of each transaction.
- 1/3 of the liquidity fee is actually used to fund the liquidity pool; while 1/3 goes to a "charity fund" address and the other 1/3 goes to the team wallet.
- The owner has the ability to set and change the "Team wallet" and "Charity Fund" addresses at any time.
- Liquidity-adds are funded by selling a portion of the tokens collected as fees (after a certain threshhold is met), then pairing the received BNB with the token, and adding it as liquidity to the BNB pair.
- The recipient of the newly created LP tokens is the contract address which causes the LP tokens to be permanently stuck in the contract, which acts as a locking mechanism.
- The owner of the contract can exclude and include accounts from tax and liquidity fees.
- The owner of the contract can exclude and include accounts from the reward distribution.
- The owner has the ability to set and update a maximum transaction percent at any time, which will impose a limit to the number of tokens that can be transferred during any given transaction.
- This maximum transaction amount does not apply to the owner during transactions where the owner is either the sender or the recipient.
- The owner has the ability to enable and disable trading. Only the owner is capable of utilizing transfer functionality while trading is disabled.
- Ownership has not been renounced.
- The contract utilizes SafeMath libraries along with following the BEP20 standard.
- No external threats were identified.
- We strongly recommend that the team renounces ownership after a successful launch.
- As with any presale, please ensure trust in the team prior to investing as they have substantial control in the ecosystem.
- Date: June 14th, 2021
|Arbitrary Storage Write||N/A||PASS|
|Delegate Call to Untrusted Contract||N/A||PASS|
|Dependence on Predictable Variables||N/A||PASS|
|State Change External Calls||N/A||PASS|
|User Supplied Assertion||N/A||PASS|
|Critical Solidity Compiler||N/A||PASS|
|Overall Contract Safety||PASS|
($) = payable function # = non-constant function + Context - [Int] _msgSender - [Int] _msgData + Ownable (Context) - [Int]
# - [Pub] owner - [Pub] renounceOwnership # - modifiers: onlyOwner - [Pub] transferOwnership # - modifiers: onlyOwner + [Lib] SafeMath - [Int] add - [Int] sub - [Int] sub - [Int] mul - [Int] div - [Int] div - [Int] mod - [Int] mod + [Int] IBEP20 - [Ext] totalSupply - [Ext] balanceOf - [Ext] transfer # - [Ext] allowance - [Ext] approve # - [Ext] transferFrom # + [Lib] Address - [Int] isContract - [Int] sendValue # - [Int] functionCall # - [Int] functionCall # - [Int] functionCallWithValue # - [Int] functionCallWithValue # - [Prv] _functionCallWithValue # + BEP20 (Context, IBEP20) - [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] _setupDecimals # - [Int] _beforeTokenTransfer # + [Lib] SafeBEP20 - [Int] safeTransfer # - [Int] safeTransferFrom # - [Int] safeApprove # - [Int] safeIncreaseAllowance # - [Int] safeDecreaseAllowance # - [Prv] _callOptionalReturn # + [Int] IPancakeFactory - [Ext] feeTo - [Ext] feeToSetter - [Ext] getPair - [Ext] allPairs - [Ext] allPairsLength - [Ext] createPair # - [Ext] setFeeTo # - [Ext] setFeeToSetter # - [Ext] INIT_CODE_PAIR_HASH + [Int] IPancakePair - [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] IPancakeRouter01 - [Ext] factory - [Ext] WETH - [Ext] addLiquidity # - [Ext] addLiquidityETH ($) - [Ext] removeLiquidity # - [Ext] removeLiquidityETH # - [Ext] removeLiquidityWithPermit # - [Ext] removeLiquidityETHWithPermit # - [Ext] swapExactTokensForTokens # - [Ext] swapTokensForExactTokens # - [Ext] swapExactETHForTokens ($) - [Ext] swapTokensForExactETH # - [Ext] swapExactTokensForETH # - [Ext] swapETHForExactTokens ($) - [Ext] quote - [Ext] getAmountOut - [Ext] getAmountIn - [Ext] getAmountsOut - [Ext] getAmountsIn + [Int] IPancakeRouter02 (IPancakeRouter01) - [Ext] removeLiquidityETHSupportingFeeOnTransferTokens # - [Ext] removeLiquidityETHWithPermitSupportingFeeOnTransferTokens # - [Ext] swapExactTokensForTokensSupportingFeeOnTransferTokens # - [Ext] swapExactETHForTokensSupportingFeeOnTransferTokens ($) - [Ext] swapExactTokensForETHSupportingFeeOnTransferTokens # + [Int] IWBNB - [Ext] deposit ($) - [Ext] withdraw # + SafeTheHumanityToken (Context, IBEP20, Ownable) - [Pub] # - [Pub] name - [Pub] symbol - [Pub] decimals - [Pub] totalSupply - [Pub] balanceOf - [Pub] transfer # - [Pub] allowance - [Pub] approve # - [Pub] transferFrom # - [Pub] increaseAllowance # - [Pub] decreaseAllowance # - [Pub] isExcludedFromReward - [Pub] totalFees - [Pub] reflectionFromToken - [Pub] tokenFromReflection - [Pub] excludeFromReward # - modifiers: onlyOwner - [Ext] includeInReward # - modifiers: onlyOwner - [Prv] _transferBothExcluded # - [Pub] excludeFromFee # - modifiers: onlyOwner - [Pub] includeInFee # - modifiers: onlyOwner - [Ext] setTaxFeePercent # - modifiers: onlyOwner - [Ext] setLiquidityFeePercent # - modifiers: onlyOwner - [Ext] setMaxTxPercent # - modifiers: onlyOwner - [Ext] setSwapAndLiquifyEnabled # - modifiers: onlyOwner - [Ext] setFundAddress # - modifiers: onlyOwner - [Ext] setTeamAddress # - modifiers: onlyOwner - [Ext] updateMinTokensBeforeSwap # - modifiers: onlyOwner - [Ext] enableTrading # - modifiers: onlyOwner - [Ext] ($) - [Prv] _reflectFee # - [Prv] _getValues - [Prv] _getTValues - [Prv] _getRValues - [Prv] _getRate - [Prv] _getCurrentSupply - [Prv] _takeLiquidity # - [Prv] calculateTaxFee - [Prv] calculateLiquidityFee - [Prv] removeAllFee # - [Prv] restoreAllFee # - [Pub] isExcludedFromFee - [Prv] _approve # - [Prv] _transfer # - [Prv] swapAndLiquify # - modifiers: lockTheSwap - [Prv] swapTokensForBnb # - [Prv] addLiquidity # - [Pub] wrap # - [Prv] _tokenTransfer # - [Prv] _transferStandard # - [Prv] _transferToExcluded # - [Prv] _transferFromExcluded #