Unable to find manual contract audit (e.g. Certik, PeckShield, Solidity...)
BABYDOGEKING.swapBack() (#613-662) sends eth to arbitrary user
Dangerous calls:
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
Ensure that an arbitrary user cannot withdraw unauthorized funds.
Additional information: link
Reentrancy in BABYDOGEKING._transferFrom(address,address,uint256) (#548-589):
External calls:
- swapBack() (#558)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#623-629)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
External calls sending eth:
- swapBack() (#558)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
State variables written after the call(s):
- _balances[sender] = _balances[sender].sub(amount,Insufficient Balance) (#566)
- _balances[recipient] = _balances[recipient].add(finalAmount) (#574)
- finalAmount = takeFee(sender,recipient,amount) (#573)
- _balances[address(this)] = _balances[address(this)].add(feeAmount) (#603)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.distributeDividend(address) (#234-246) ignores return value by RewardToken.transfer(shareholder,amount) (#240)
Use SafeERC20, or ensure that the transfer/transferFrom return value is checked.
Additional information: link
Too many vulnerabilities (Unchecked transfer, Reentrancy vulnerability, etc.). High risk of a scam. DYOR & manual audit are advised.
BABYDOGEKING.swapBack().tmpSuccess (#644) is written in both
(tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
tmpSuccess = false (#648)
BABYDOGEKING.swapBack().tmpSuccess1 (#645) is written in both
(tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
tmpSuccess1 = false (#649)
Fix or remove the writes.
Additional information: link
Combination 1: Reentrancy vulnerabilities + Functions that send Ether to arbitraty destination. Usual for scams. May be justified by some complex mechanics (e.g. rebase, reflections). DYOR & manual audit are advised.
Combination 2: Unchecked transfer + Functions that send Ether to arbitraty destination. Usual for scams. May be justified by some complex mechanics (e.g. rebase, reflections). DYOR & manual audit are advised.
Combination 3: Reentrancy vulnerabilities + Unchecked transfer vulnerability. Usual for scams. May be justified by some complex mechanics (e.g. rebase, reflections). DYOR & manual audit are advised.
Not a direct threat, but may indicate unreliable intentions of developer. Widespread names (e.g. Elon, King, Moon, Doge) are common among meme-tokens and scams. The allow to gain free hype and attract unexperienced investors.
BABYDOGEKING._maxTxAmount (#356) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 5 / 100
BABYDOGEKING._walletMax (#357) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 5 / 100
BABYDOGEKING.swapThreshold (#393) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 5 / 2000
Remove any initialization of state variables via non-constant state variables or function calls. If variables must be set upon contract deployment, locate initialization in the constructor instead.
Additional information: link
Pragma version^0.7.4 (#3) allows old versions
solc-0.7.4 is not recommended for deployment
Deploy with any of the following Solidity versions: 0.5.16 - 0.5.17, 0.6.11 - 0.6.12, 0.7.5 - 0.7.6 Use a simple pragma version that allows any of these versions. Consider using the latest version of Solidity for testing.
Additional information: link
Low level call in BABYDOGEKING.swapBack() (#613-662):
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
Avoid low-level calls. Check the call success. If the call is meant for a contract, check for code existence
Additional information: link
Reentrancy in DividendDistributor.distributeDividend(address) (#234-246):
External calls:
- RewardToken.transfer(shareholder,amount) (#240)
State variables written after the call(s):
- shares[shareholder].totalRealised = shares[shareholder].totalRealised.add(amount) (#242)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#243)
Reentrancy in DividendDistributor.process(uint256) (#205-227):
External calls:
- distributeDividend(shareholders[currentIndex]) (#219)
- RewardToken.transfer(shareholder,amount) (#240)
State variables written after the call(s):
- currentIndex ++ (#224)
Reentrancy in DividendDistributor.setShare(address,uint256) (#168-183):
External calls:
- distributeDividend(shareholder) (#171)
- RewardToken.transfer(shareholder,amount) (#240)
State variables written after the call(s):
- shares[shareholder].amount = amount (#181)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#182)
Apply the check-effects-interactions pattern.
Additional information: link
BABYDOGEKING.swapBack() (#613-662) ignores return value by router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
Ensure that all the return values of the function calls are used.
Additional information: link
DividendDistributor.setDistributionCriteria(uint256,uint256) (#163-166) should emit an event for:
- minPeriod = newMinPeriod (#164)
- minDistribution = newMinDistribution (#165)
BABYDOGEKING.changeFees(uint256,uint256,uint256,uint256) (#505-513) should emit an event for:
- liquidityFee = newLiqFee (#506)
- rewardsFee = newRewardFee (#507)
- totalFee = liquidityFee.add(marketingFee).add(rewardsFee) (#511)
- totalFeeIfSelling = totalFee.add(extraFeeOnSell) (#512)
Emit an event for critical parameter changes.
Additional information: link
Auth.transferOwnership(address).adr (#333) lacks a zero-check on :
- owner = adr (#334)
BABYDOGEKING.changeFeeReceivers(address,address,address).newLiquidityReceiver (#515) lacks a zero-check on :
- autoLiquidityReceiver = newLiquidityReceiver (#516)
BABYDOGEKING.changeFeeReceivers(address,address,address).newMarketingWallet (#515) lacks a zero-check on :
- marketingWallet = newMarketingWallet (#517)
BABYDOGEKING.changeFeeReceivers(address,address,address).newanothermarketingWallet (#515) lacks a zero-check on :
- anothermarketingWallet = newanothermarketingWallet (#518)
Check that the address is not zero.
Additional information: link
DividendDistributor.distributeDividend(address) (#234-246) has external calls inside a loop: RewardToken.transfer(shareholder,amount) (#240)
Favor pull over push strategy for external calls.
Additional information: link
Reentrancy in BABYDOGEKING._transferFrom(address,address,uint256) (#548-589):
External calls:
- swapBack() (#558)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#623-629)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
External calls sending eth:
- swapBack() (#558)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
State variables written after the call(s):
- launch() (#562)
- launchedAt = block.number (#471)
Reentrancy in BABYDOGEKING.constructor() (#401-433):
External calls:
- pair = IDEXFactory(router.factory()).createPair(router.WETH(),address(this)) (#404)
State variables written after the call(s):
- _allowances[address(this)][address(router)] = uint256(- 1) (#405)
- _balances[msg.sender] = _totalSupply (#431)
- anothermarketingWallet = 0x29D96Ab6aE292Cde9F4c16F5F1420696e1694707 (#426)
- autoLiquidityReceiver = msg.sender (#424)
- dividendDistributor = new DividendDistributor(address(router)) (#407)
- isDividendExempt[pair] = true (#417)
- isDividendExempt[address(this)] = true (#419)
- isDividendExempt[DEAD] = true (#420)
- isDividendExempt[ZERO] = true (#421)
- isFeeExempt[msg.sender] = true (#409)
- isFeeExempt[address(this)] = true (#410)
- isFeeExempt[anothermarketingWallet] = true (#411)
- isTxLimitExempt[msg.sender] = true (#413)
- isTxLimitExempt[pair] = true (#414)
- isTxLimitExempt[DEAD] = true (#415)
- marketingWallet = msg.sender (#425)
- totalFee = liquidityFee.add(marketingFee).add(rewardsFee) (#428)
- totalFeeIfSelling = totalFee.add(extraFeeOnSell) (#429)
Reentrancy in DividendDistributor.deposit() (#185-203):
External calls:
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: msg.value}(0,path,address(this),block.timestamp) (#193-198)
State variables written after the call(s):
- dividendsPerShare = dividendsPerShare.add(dividendsPerShareAccuracyFactor.mul(amount).div(totalShares)) (#202)
- totalDividends = totalDividends.add(amount) (#201)
Reentrancy in DividendDistributor.distributeDividend(address) (#234-246):
External calls:
- RewardToken.transfer(shareholder,amount) (#240)
State variables written after the call(s):
- shareholderClaims[shareholder] = block.timestamp (#241)
Reentrancy in DividendDistributor.setShare(address,uint256) (#168-183):
External calls:
- distributeDividend(shareholder) (#171)
- RewardToken.transfer(shareholder,amount) (#240)
State variables written after the call(s):
- addShareholder(shareholder) (#175)
- shareholderIndexes[shareholder] = shareholders.length (#264)
- removeShareholder(shareholder) (#177)
- shareholderIndexes[shareholders[shareholders.length - 1]] = shareholderIndexes[shareholder] (#270)
- addShareholder(shareholder) (#175)
- shareholders.push(shareholder) (#265)
- removeShareholder(shareholder) (#177)
- shareholders[shareholderIndexes[shareholder]] = shareholders[shareholders.length - 1] (#269)
- shareholders.pop() (#271)
- totalShares = totalShares.sub(shares[shareholder].amount).add(amount) (#180)
Apply the check-effects-interactions pattern.
Additional information: link
Reentrancy in BABYDOGEKING._transferFrom(address,address,uint256) (#548-589):
External calls:
- swapBack() (#558)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#623-629)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
- dividendDistributor.setShare(sender,_balances[sender]) (#578)
- dividendDistributor.setShare(recipient,_balances[recipient]) (#582)
- dividendDistributor.process(distributorGas) (#585)
External calls sending eth:
- swapBack() (#558)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
Event emitted after the call(s):
- Transfer(sender,recipient,finalAmount) (#587)
Reentrancy in BABYDOGEKING._transferFrom(address,address,uint256) (#548-589):
External calls:
- swapBack() (#558)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#623-629)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
External calls sending eth:
- swapBack() (#558)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
Event emitted after the call(s):
- Transfer(sender,address(this),feeAmount) (#604)
- finalAmount = takeFee(sender,recipient,amount) (#573)
Reentrancy in BABYDOGEKING.constructor() (#401-433):
External calls:
- pair = IDEXFactory(router.factory()).createPair(router.WETH(),address(this)) (#404)
Event emitted after the call(s):
- Transfer(address(0),msg.sender,_totalSupply) (#432)
Reentrancy in BABYDOGEKING.swapBack() (#613-662):
External calls:
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#623-629)
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
External calls sending eth:
- dividendDistributor.deposit{value: amountBNBReflection}() (#639)
- (tmpSuccess) = address(marketingWallet).call{gas: 30000,value: marketingShare}() (#644)
- (tmpSuccess1) = address(anothermarketingWallet).call{gas: 30000,value: anothermarketingShare}() (#645)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#652-659)
Event emitted after the call(s):
- AutoLiquify(amountBNBLiquidity,amountToLiquify) (#660)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.shouldDistribute(address) (#229-232) uses timestamp for comparisons
Dangerous comparisons:
- shareholderClaims[shareholder] + minPeriod < block.timestamp && getUnpaidEarnings(shareholder) > minDistribution (#230-231)
Avoid relying on block.timestamp.
Additional information: link
DividendDistributor.process(uint256) (#205-227) has costly operations inside a loop:
- currentIndex = 0 (#216)
DividendDistributor.distributeDividend(address) (#234-246) has costly operations inside a loop:
- totalDistributed = totalDistributed.add(amount) (#239)
DividendDistributor.process(uint256) (#205-227) has costly operations inside a loop:
- currentIndex ++ (#224)
Use a local variable to hold the loop computation result.
Additional information: link
Function IDEXRouter.WETH() (#62) is not in mixedCase
Variable DividendDistributor._token (#119) is not in mixedCase
Variable DividendDistributor.RewardToken (#129) is not in mixedCase
Constant BABYDOGEKING._name (#346) is not in UPPER_CASE_WITH_UNDERSCORES
Constant BABYDOGEKING._symbol (#347) is not in UPPER_CASE_WITH_UNDERSCORES
Constant BABYDOGEKING._decimals (#348) is not in UPPER_CASE_WITH_UNDERSCORES
Variable BABYDOGEKING.DEAD (#350) is not in mixedCase
Variable BABYDOGEKING.ZERO (#351) is not in mixedCase
Variable BABYDOGEKING.RewardToken (#353) is not in mixedCase
Variable BABYDOGEKING._totalSupply (#355) is not in mixedCase
Variable BABYDOGEKING._maxTxAmount (#356) is not in mixedCase
Variable BABYDOGEKING._walletMax (#357) is not in mixedCase
Variable BABYDOGEKING._balances (#361) is not in mixedCase
Variable BABYDOGEKING._allowances (#362) is not in mixedCase
Follow the Solidity naming convention.
Additional information: link
Variable IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountADesired (#67) is too similar to IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountBDesired (#68)
Prevent variables from having similar names.
Additional information: link
BABYDOGEKING.slitherConstructorVariables() (#342-667) uses literals with too many digits:
- DEAD = 0x000000000000000000000000000000000000dEaD (#350)
BABYDOGEKING.slitherConstructorVariables() (#342-667) uses literals with too many digits:
- ZERO = 0x0000000000000000000000000000000000000000 (#351)
BABYDOGEKING.slitherConstructorVariables() (#342-667) uses literals with too many digits:
- _totalSupply = 1000000 * (10 ** _decimals) (#355)
BABYDOGEKING.slitherConstructorVariables() (#342-667) uses literals with too many digits:
- distributorGas = 300000 (#387)
Use: Ether suffix, Time suffix, or The scientific notation
Additional information: link
BABYDOGEKING.RewardToken (#353) is never used in BABYDOGEKING (#342-667)
Remove unused state variables.
Additional information: link
BABYDOGEKING.DEAD (#350) should be constant
BABYDOGEKING.RewardToken (#353) should be constant
BABYDOGEKING.ZERO (#351) should be constant
BABYDOGEKING._totalSupply (#355) should be constant
BABYDOGEKING.routerAddress (#352) should be constant
DividendDistributor.dividendsPerShareAccuracyFactor (#140) should be constant
DividendDistributor.routerAddress (#128) should be constant
Add the constant attributes to state variables that never change.
Additional information: link
authorize(address) should be declared external:
- Auth.authorize(address) (#305-307)
unauthorize(address) should be declared external:
- Auth.unauthorize(address) (#312-314)
transferOwnership(address) should be declared external:
- Auth.transferOwnership(address) (#333-337)
getCirculatingSupply() should be declared external:
- BABYDOGEKING.getCirculatingSupply() (#443-445)
claim() should be declared external:
- BABYDOGEKING.claim() (#461-464)
tradingStatus(bool) should be declared external:
- BABYDOGEKING.tradingStatus(bool) (#609-611)
Use the external attribute for functions never called from the contract.
Additional information: link
Unable to find website, listings and other project-related information
Young tokens have high risks of scam / price dump / death
Token has no active CoinGecko listing / rank
Token has no active CoinMarketCap listing / rank
Unable to find Twitter account
Unable to find Blog account (Reddit or Medium)
Unable to find Youtube account
Unable to find Discord account