DogeClassic.swapBack() (#670-712) sends eth to arbitrary user
Dangerous calls:
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
Ensure that an arbitrary user cannot withdraw unauthorized funds.
Additional information: link
Reentrancy in DogeClassic._transferFrom(address,address,uint256) (#600-627):
External calls:
- swapBack() (#610)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#681-687)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
External calls sending eth:
- swapBack() (#610)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
State variables written after the call(s):
- _balances[sender] = _balances[sender].sub(amount,Insufficient Balance) (#615)
- _balances[recipient] = _balances[recipient].add(amountReceived) (#618)
- amountReceived = takeFee(sender,recipient,amount) (#617)
- _balances[address(this)] = _balances[address(this)].add(feeAmount) (#657)
- triggerAutoBuyback() (#611)
- inSwap = true (#545)
- inSwap = false (#545)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.distributeDividend(address) (#439-450) ignores return value by REWARD.transfer(shareholder,amount) (#445)
Use SafeERC20, or ensure that the transfer/transferFrom return value is checked.
Additional information: link
Unable to find manual contract audit (e.g. Certik, PeckShield, Solidity...)
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.
Contract ownership is not renounced (belongs to a wallet)
Reentrancy in DividendDistributor.distributeDividend(address) (#439-450):
External calls:
- REWARD.transfer(shareholder,amount) (#445)
State variables written after the call(s):
- shares[shareholder].totalRealised = shares[shareholder].totalRealised.add(amount) (#447)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#448)
Reentrancy in DividendDistributor.process(uint256) (#408-432):
External calls:
- distributeDividend(shareholders[currentIndex]) (#424)
- REWARD.transfer(shareholder,amount) (#445)
State variables written after the call(s):
- currentIndex ++ (#429)
Reentrancy in DividendDistributor.setShare(address,uint256) (#371-385):
External calls:
- distributeDividend(shareholder) (#373)
- REWARD.transfer(shareholder,amount) (#445)
State variables written after the call(s):
- shares[shareholder].amount = amount (#383)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#384)
Apply the check-effects-interactions pattern.
Additional information: link
DogeClassic.swapBack() (#670-712) ignores return value by router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
Ensure that all the return values of the function calls are used.
Additional information: link
DividendDistributor.setDistributionCriteria(uint256,uint256) (#366-369) should emit an event for:
- minPeriod = _minPeriod (#367)
- minDistribution = _minDistribution (#368)
DogeClassic.setAutoBuybackSettings(bool,uint256,uint256,uint256) (#754-761) should emit an event for:
- autoBuybackCap = _cap (#756)
- autoBuybackAmount = _amount.div(100) (#758)
DogeClassic.setTxLimit(uint256) (#778-781) should emit an event for:
- _maxTxAmount = amount.div(100) (#780)
DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256) (#808-815) should emit an event for:
- liquidityFee = _liquidityFee (#809)
- reflectionFee = _reflectionFee (#811)
- marketingFee = _marketingFee (#812)
- totalFee = _liquidityFee.add(_buybackFee).add(_reflectionFee).add(_marketingFee) (#813)
- feeDenominator = _feeDenominator (#814)
DogeClassic.setSwapBackSettings(bool,uint256) (#822-825) should emit an event for:
- swapThreshold = _amount.div(100) (#824)
DogeClassic.setTargetLiquidity(uint256,uint256) (#827-830) should emit an event for:
- targetLiquidity = _target (#828)
- targetLiquidityDenominator = _denominator (#829)
Emit an event for critical parameter changes.
Additional information: link
DogeClassic.setFeeReceivers(address,address)._autoLiquidityReceiver (#817) lacks a zero-check on :
- autoLiquidityReceiver = _autoLiquidityReceiver (#818)
DogeClassic.setFeeReceivers(address,address)._marketingFeeReceiver (#817) lacks a zero-check on :
- marketingFeeReceiver = _marketingFeeReceiver (#819)
Check that the address is not zero.
Additional information: link
DividendDistributor.distributeDividend(address) (#439-450) has external calls inside a loop: REWARD.transfer(shareholder,amount) (#445)
Favor pull over push strategy for external calls.
Additional information: link
Reentrancy in DogeClassic._transferFrom(address,address,uint256) (#600-627):
External calls:
- swapBack() (#610)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#681-687)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
External calls sending eth:
- swapBack() (#610)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
State variables written after the call(s):
- launch() (#613)
- launchedAt = block.number (#775)
Reentrancy in DogeClassic.constructor() (#547-566):
External calls:
- pair = IDEXFactory(router.factory()).createPair(WBNB,address(this)) (#549)
State variables written after the call(s):
- _allowances[address(this)][address(router)] = uint256(- 1) (#550)
- _balances[msg.sender] = _totalSupply (#564)
- autoLiquidityReceiver = msg.sender (#561)
- distributor = new DividendDistributor(address(router)) (#552)
- isDividendExempt[pair] = true (#557)
- isDividendExempt[address(this)] = true (#558)
- isDividendExempt[DEAD] = true (#559)
- isDividendExempt[ZERO] = true (#560)
- isFeeExempt[msg.sender] = true (#554)
- isTxLimitExempt[msg.sender] = true (#555)
- isTxLimitExempt[address(router)] = true (#556)
- marketingFeeReceiver = msg.sender (#562)
Reentrancy in DividendDistributor.deposit() (#388-406):
External calls:
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: msg.value}(0,path,address(this),block.timestamp) (#395-400)
State variables written after the call(s):
- dividendsPerShare = dividendsPerShare.add(dividendsPerShareAccuracyFactor.mul(amount).div(totalShares)) (#405)
- totalDividends = totalDividends.add(amount) (#404)
Reentrancy in DividendDistributor.distributeDividend(address) (#439-450):
External calls:
- REWARD.transfer(shareholder,amount) (#445)
State variables written after the call(s):
- shareholderClaims[shareholder] = block.timestamp (#446)
Reentrancy in DividendDistributor.setShare(address,uint256) (#371-385):
External calls:
- distributeDividend(shareholder) (#373)
- REWARD.transfer(shareholder,amount) (#445)
State variables written after the call(s):
- addShareholder(shareholder) (#377)
- shareholderIndexes[shareholder] = shareholders.length (#472)
- removeShareholder(shareholder) (#379)
- shareholderIndexes[shareholders[shareholders.length - 1]] = shareholderIndexes[shareholder] (#478)
- addShareholder(shareholder) (#377)
- shareholders.push(shareholder) (#473)
- removeShareholder(shareholder) (#379)
- shareholders[shareholderIndexes[shareholder]] = shareholders[shareholders.length - 1] (#477)
- shareholders.pop() (#479)
- totalShares = totalShares.sub(shares[shareholder].amount).add(amount) (#382)
Reentrancy in DogeClassic.triggerAutoBuyback() (#734-739):
External calls:
- buyTokens(autoBuybackAmount,DEAD) (#735)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
State variables written after the call(s):
- autoBuybackAccumulator = autoBuybackAccumulator.add(autoBuybackAmount) (#737)
- autoBuybackBlockLast = block.number (#736)
- autoBuybackEnabled = false (#738)
Reentrancy in DogeClassic.triggerManualBuyback(uint256,bool) (#722-728):
External calls:
- buyTokens(amount,DEAD) (#723)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
State variables written after the call(s):
- buybackMultiplierTriggeredAt = block.timestamp (#725)
Apply the check-effects-interactions pattern.
Additional information: link
Reentrancy in DogeClassic._transferFrom(address,address,uint256) (#600-627):
External calls:
- swapBack() (#610)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#681-687)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
- distributor.setShare(sender,_balances[sender]) (#620)
- distributor.setShare(recipient,_balances[recipient]) (#621)
- distributor.process(distributorGas) (#623)
External calls sending eth:
- swapBack() (#610)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
Event emitted after the call(s):
- Transfer(sender,recipient,amountReceived) (#625)
Reentrancy in DogeClassic._transferFrom(address,address,uint256) (#600-627):
External calls:
- swapBack() (#610)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#681-687)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
External calls sending eth:
- swapBack() (#610)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
- triggerAutoBuyback() (#611)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
Event emitted after the call(s):
- Transfer(sender,address(this),feeAmount) (#658)
- amountReceived = takeFee(sender,recipient,amount) (#617)
Reentrancy in DogeClassic.constructor() (#547-566):
External calls:
- pair = IDEXFactory(router.factory()).createPair(WBNB,address(this)) (#549)
Event emitted after the call(s):
- Transfer(address(0),msg.sender,_totalSupply) (#565)
Reentrancy in DogeClassic.swapBack() (#670-712):
External calls:
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#681-687)
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
External calls sending eth:
- distributor.deposit{value: amountBNBReflection}() (#697)
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#702-709)
Event emitted after the call(s):
- AutoLiquify(amountBNBLiquidity,amountToLiquify) (#710)
Reentrancy in DogeClassic.triggerManualBuyback(uint256,bool) (#722-728):
External calls:
- buyTokens(amount,DEAD) (#723)
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: amount}(0,path,to,block.timestamp) (#746-751)
Event emitted after the call(s):
- BuybackMultiplierActive(buybackMultiplierLength) (#726)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.shouldDistribute(address) (#434-437) uses timestamp for comparisons
Dangerous comparisons:
- shareholderClaims[shareholder] + minPeriod < block.timestamp && getUnpaidEarnings(shareholder) > minDistribution (#435-436)
Avoid relying on block.timestamp.
Additional information: link
Address.isContract(address) (#24-33) uses assembly
- INLINE ASM (#31)
Address._functionCallWithValue(address,bytes,uint256,string) (#60-81) uses assembly
- INLINE ASM (#73-76)
Do not use evm assembly.
Additional information: link
DividendDistributor.process(uint256) (#408-432) has costly operations inside a loop:
- currentIndex = 0 (#420)
DividendDistributor.distributeDividend(address) (#439-450) has costly operations inside a loop:
- totalDistributed = totalDistributed.add(amount) (#444)
DividendDistributor.process(uint256) (#408-432) has costly operations inside a loop:
- currentIndex ++ (#429)
Use a local variable to hold the loop computation result.
Additional information: link
Address._functionCallWithValue(address,bytes,uint256,string) (#60-81) is never used and should be removed
Address.functionCall(address,bytes) (#43-45) is never used and should be removed
Address.functionCall(address,bytes,string) (#47-49) is never used and should be removed
Address.functionCallWithValue(address,bytes,uint256) (#51-53) is never used and should be removed
Address.functionCallWithValue(address,bytes,uint256,string) (#55-58) is never used and should be removed
Address.isContract(address) (#24-33) is never used and should be removed
Address.sendValue(address,uint256) (#35-41) is never used and should be removed
Context._msgData() (#89-92) is never used and should be removed
Remove unused functions.
Additional information: link
DogeClassic._maxTxAmount (#498) is set pre-construction with a non-constant function or state variable:
- (_totalSupply * 4) / 200
DogeClassic._maxWalletSize (#499) is set pre-construction with a non-constant function or state variable:
- (_totalSupply * 4) / 200
DogeClassic.swapThreshold (#543) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 45 / 10000
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.2 (#20) allows old versions
solc-0.7.2 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 Address.sendValue(address,uint256) (#35-41):
- (success) = recipient.call{value: amount}() (#39)
Low level call in Address._functionCallWithValue(address,bytes,uint256,string) (#60-81):
- (success,returndata) = target.call{value: weiValue}(data) (#64)
Low level call in DogeClassic.swapBack() (#670-712):
- (success) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBDev}() (#698)
Avoid low-level calls. Check the call success. If the call is meant for a contract, check for code existence
Additional information: link
Function IDEXRouter.WETH() (#262) is not in mixedCase
Parameter DividendDistributor.setDistributionCriteria(uint256,uint256)._minPeriod (#366) is not in mixedCase
Parameter DividendDistributor.setDistributionCriteria(uint256,uint256)._minDistribution (#366) is not in mixedCase
Variable DividendDistributor._token (#318) is not in mixedCase
Variable DividendDistributor.REWARD (#327) is not in mixedCase
Variable DividendDistributor.WBNB (#328) is not in mixedCase
Parameter DogeClassic.setAutoBuybackSettings(bool,uint256,uint256,uint256)._enabled (#754) is not in mixedCase
Parameter DogeClassic.setAutoBuybackSettings(bool,uint256,uint256,uint256)._cap (#754) is not in mixedCase
Parameter DogeClassic.setAutoBuybackSettings(bool,uint256,uint256,uint256)._amount (#754) is not in mixedCase
Parameter DogeClassic.setAutoBuybackSettings(bool,uint256,uint256,uint256)._period (#754) is not in mixedCase
Parameter DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256)._liquidityFee (#808) is not in mixedCase
Parameter DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256)._buybackFee (#808) is not in mixedCase
Parameter DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256)._reflectionFee (#808) is not in mixedCase
Parameter DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256)._marketingFee (#808) is not in mixedCase
Parameter DogeClassic.setFees(uint256,uint256,uint256,uint256,uint256)._feeDenominator (#808) is not in mixedCase
Parameter DogeClassic.setFeeReceivers(address,address)._autoLiquidityReceiver (#817) is not in mixedCase
Parameter DogeClassic.setFeeReceivers(address,address)._marketingFeeReceiver (#817) is not in mixedCase
Parameter DogeClassic.setSwapBackSettings(bool,uint256)._enabled (#822) is not in mixedCase
Parameter DogeClassic.setSwapBackSettings(bool,uint256)._amount (#822) is not in mixedCase
Parameter DogeClassic.setTargetLiquidity(uint256,uint256)._target (#827) is not in mixedCase
Parameter DogeClassic.setTargetLiquidity(uint256,uint256)._denominator (#827) is not in mixedCase
Parameter DogeClassic.setDistributionCriteria(uint256,uint256)._minPeriod (#832) is not in mixedCase
Parameter DogeClassic.setDistributionCriteria(uint256,uint256)._minDistribution (#832) is not in mixedCase
Variable DogeClassic.REWARD (#488) is not in mixedCase
Variable DogeClassic.WBNB (#489) is not in mixedCase
Variable DogeClassic.DEAD (#490) is not in mixedCase
Variable DogeClassic.ZERO (#491) is not in mixedCase
Constant DogeClassic._name (#493) is not in UPPER_CASE_WITH_UNDERSCORES
Constant DogeClassic._symbol (#494) is not in UPPER_CASE_WITH_UNDERSCORES
Constant DogeClassic._decimals (#495) is not in UPPER_CASE_WITH_UNDERSCORES
Variable DogeClassic._totalSupply (#497) is not in mixedCase
Variable DogeClassic._maxTxAmount (#498) is not in mixedCase
Variable DogeClassic._maxWalletSize (#499) is not in mixedCase
Variable DogeClassic._balances (#501) is not in mixedCase
Variable DogeClassic._allowances (#502) is not in mixedCase
Follow the Solidity naming convention.
Additional information: link
Redundant expression "this (#90)" inContext (#84-93)
Remove redundant statements if they congest code but offer no value.
Additional information: link
Variable IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountADesired (#267) is too similar to IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountBDesired (#268)
Prevent variables from having similar names.
Additional information: link
DogeClassic.slitherConstructorVariables() (#484-862) uses literals with too many digits:
- DEAD = 0x000000000000000000000000000000000000dEaD (#490)
DogeClassic.slitherConstructorVariables() (#484-862) uses literals with too many digits:
- ZERO = 0x0000000000000000000000000000000000000000 (#491)
DogeClassic.slitherConstructorVariables() (#484-862) uses literals with too many digits:
- distributorGas = 500000 (#540)
Use: Ether suffix, Time suffix, or The scientific notation
Additional information: link
DogeClassic.REWARD (#488) is never used in DogeClassic (#484-862)
Remove unused state variables.
Additional information: link
DividendDistributor.WBNB (#328) should be constant
DividendDistributor.dividendsPerShareAccuracyFactor (#341) should be constant
DogeClassic.DEAD (#490) should be constant
DogeClassic.REWARD (#488) should be constant
DogeClassic.WBNB (#489) should be constant
DogeClassic.ZERO (#491) should be constant
DogeClassic._totalSupply (#497) should be constant
Add the constant attributes to state variables that never change.
Additional information: link
renounceOwnership() should be declared external:
- Ownable.renounceOwnership() (#240-243)
transferOwnership(address) should be declared external:
- Ownable.transferOwnership(address) (#249-253)
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 Telegram and Twitter accounts