Unable to find manual contract audit (e.g. Certik, PeckShield, Solidity...)
BabyMcDollar.swapBack() (#582-626) sends eth to arbitrary user
Dangerous calls:
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
Ensure that an arbitrary user cannot withdraw unauthorized funds.
Additional information: link
Reentrancy in BabyMcDollar._transferFrom(address,address,uint256) (#485-533):
External calls:
- swapBack() (#512)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#593-599)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
External calls sending eth:
- swapBack() (#512)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
State variables written after the call(s):
- _balances[sender] = _balances[sender].sub(amount,Insufficient Balance) (#515)
- _balances[recipient] = _balances[recipient].add(amountReceived) (#518)
- amountReceived = takeFee(sender,amount) (#517)
- _balances[address(this)] = _balances[address(this)].add(feeAmount) (#553)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.distributeDividend(address) (#313-324) ignores return value by McdollarReward.transfer(shareholder,amount) (#319)
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.
BabyMcDollar.swapBack().tmpSuccess (#610) is written in both
(tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
tmpSuccess = false (#613)
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.
Contract ticker (Baby McDollar) contains non-alphanumeric characters.
Not a direct threat, but may indicate unreliable intentions of developer. Non-alphanumeric chars (,.;!#*&") are extremely rare among low risk tokens.
Reentrancy in DividendDistributor.distributeDividend(address) (#313-324):
External calls:
- McdollarReward.transfer(shareholder,amount) (#319)
State variables written after the call(s):
- shares[shareholder].totalRealised = shares[shareholder].totalRealised.add(amount) (#321)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#322)
Reentrancy in DividendDistributor.process(uint256) (#282-306):
External calls:
- distributeDividend(shareholders[currentIndex]) (#298)
- McdollarReward.transfer(shareholder,amount) (#319)
State variables written after the call(s):
- currentIndex ++ (#303)
Reentrancy in DividendDistributor.setShare(address,uint256) (#246-260):
External calls:
- distributeDividend(shareholder) (#248)
- McdollarReward.transfer(shareholder,amount) (#319)
State variables written after the call(s):
- shares[shareholder].amount = amount (#258)
- shares[shareholder].totalExcluded = getCumulativeDividends(shares[shareholder].amount) (#259)
Apply the check-effects-interactions pattern.
Additional information: link
BabyMcDollar.swapBack() (#582-626) ignores return value by router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
Ensure that all the return values of the function calls are used.
Additional information: link
DividendDistributor.setDistributionCriteria(uint256,uint256) (#241-244) should emit an event for:
- minPeriod = _minPeriod (#242)
- minDistribution = _minDistribution (#243)
BabyMcDollar.setTxLimit(uint256) (#629-631) should emit an event for:
- _maxTxAmount = amount (#630)
BabyMcDollar.setFees(uint256,uint256,uint256,uint256) (#655-662) should emit an event for:
- liquidityFee = _liquidityFee (#656)
- reflectionFee = _reflectionFee (#657)
- marketingFee = _marketingFee (#658)
- totalFee = _liquidityFee.add(_reflectionFee).add(_marketingFee) (#659)
- feeDenominator = _feeDenominator (#660)
BabyMcDollar.setSwapBackSettings(bool,uint256) (#669-672) should emit an event for:
- swapThreshold = _amount (#671)
BabyMcDollar.setTargetLiquidity(uint256,uint256) (#674-677) should emit an event for:
- targetLiquidity = _target (#675)
- targetLiquidityDenominator = _denominator (#676)
Emit an event for critical parameter changes.
Additional information: link
Auth.transferOwnership(address).adr (#122) lacks a zero-check on :
- owner = adr (#123)
BabyMcDollar.setFeeReceivers(address,address)._autoLiquidityReceiver (#664) lacks a zero-check on :
- autoLiquidityReceiver = _autoLiquidityReceiver (#665)
BabyMcDollar.setFeeReceivers(address,address)._marketingFeeReceiver (#664) lacks a zero-check on :
- marketingFeeReceiver = _marketingFeeReceiver (#666)
Check that the address is not zero.
Additional information: link
DividendDistributor.distributeDividend(address) (#313-324) has external calls inside a loop: McdollarReward.transfer(shareholder,amount) (#319)
BabyMcDollar.airdrop(address,address[],uint256[]) (#705-728) has external calls inside a loop: distributor.setShare(addresses[i_scope_0],_balances[addresses[i_scope_0]]) (#720)
Favor pull over push strategy for external calls.
Additional information: link
Reentrancy in BabyMcDollar.constructor() (#414-446):
External calls:
- pair = IDEXFactory(router.factory()).createPair(WBNB,address(this)) (#418)
State variables written after the call(s):
- _allowances[address(this)][address(router)] = uint256(- 1) (#419)
- _balances[msg.sender] = _totalSupply (#444)
- autoLiquidityReceiver = DEAD (#441)
- distributor = new DividendDistributor(address(router)) (#421)
- isDividendExempt[pair] = true (#436)
- isDividendExempt[address(this)] = true (#437)
- isDividendExempt[DEAD] = true (#438)
- isFeeExempt[msg.sender] = true (#423)
- isTimelockExempt[msg.sender] = true (#427)
- isTimelockExempt[DEAD] = true (#428)
- isTimelockExempt[address(this)] = true (#429)
- isTxLimitExempt[msg.sender] = true (#424)
- marketingFeeReceiver = msg.sender (#442)
Reentrancy in DividendDistributor.deposit() (#262-280):
External calls:
- router.swapExactETHForTokensSupportingFeeOnTransferTokens{value: msg.value}(0,path,address(this),block.timestamp) (#269-274)
State variables written after the call(s):
- dividendsPerShare = dividendsPerShare.add(dividendsPerShareAccuracyFactor.mul(amount).div(totalShares)) (#279)
- totalDividends = totalDividends.add(amount) (#278)
Reentrancy in DividendDistributor.distributeDividend(address) (#313-324):
External calls:
- McdollarReward.transfer(shareholder,amount) (#319)
State variables written after the call(s):
- shareholderClaims[shareholder] = block.timestamp (#320)
Reentrancy in DividendDistributor.setShare(address,uint256) (#246-260):
External calls:
- distributeDividend(shareholder) (#248)
- McdollarReward.transfer(shareholder,amount) (#319)
State variables written after the call(s):
- addShareholder(shareholder) (#252)
- shareholderIndexes[shareholder] = shareholders.length (#346)
- removeShareholder(shareholder) (#254)
- shareholderIndexes[shareholders[shareholders.length - 1]] = shareholderIndexes[shareholder] (#352)
- addShareholder(shareholder) (#252)
- shareholders.push(shareholder) (#347)
- removeShareholder(shareholder) (#254)
- shareholders[shareholderIndexes[shareholder]] = shareholders[shareholders.length - 1] (#351)
- shareholders.pop() (#353)
- totalShares = totalShares.sub(shares[shareholder].amount).add(amount) (#257)
Apply the check-effects-interactions pattern.
Additional information: link
Reentrancy in BabyMcDollar._transferFrom(address,address,uint256) (#485-533):
External calls:
- swapBack() (#512)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#593-599)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
- distributor.setShare(sender,_balances[sender]) (#522)
- distributor.setShare(recipient,_balances[recipient]) (#526)
- distributor.process(distributorGas) (#529)
External calls sending eth:
- swapBack() (#512)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
Event emitted after the call(s):
- Transfer(sender,recipient,amountReceived) (#531)
Reentrancy in BabyMcDollar._transferFrom(address,address,uint256) (#485-533):
External calls:
- swapBack() (#512)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#593-599)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
External calls sending eth:
- swapBack() (#512)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
Event emitted after the call(s):
- Transfer(sender,address(this),feeAmount) (#554)
- amountReceived = takeFee(sender,amount) (#517)
Reentrancy in BabyMcDollar.constructor() (#414-446):
External calls:
- pair = IDEXFactory(router.factory()).createPair(WBNB,address(this)) (#418)
Event emitted after the call(s):
- Transfer(address(0),msg.sender,_totalSupply) (#445)
Reentrancy in BabyMcDollar.swapBack() (#582-626):
External calls:
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#593-599)
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
External calls sending eth:
- distributor.deposit{value: amountBNBReflection}() (#609)
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
- router.addLiquidityETH{value: amountBNBLiquidity}(address(this),amountToLiquify,0,0,autoLiquidityReceiver,block.timestamp) (#616-623)
Event emitted after the call(s):
- AutoLiquify(amountBNBLiquidity,amountToLiquify) (#624)
Apply the check-effects-interactions pattern.
Additional information: link
DividendDistributor.shouldDistribute(address) (#308-311) uses timestamp for comparisons
Dangerous comparisons:
- shareholderClaims[shareholder] + minPeriod < block.timestamp && getUnpaidEarnings(shareholder) > minDistribution (#309-310)
BabyMcDollar._transferFrom(address,address,uint256) (#485-533) uses timestamp for comparisons
Dangerous comparisons:
- require(bool,string)(cooldownTimer[recipient] < block.timestamp,Please wait for cooldown between buys) (#503)
Avoid relying on block.timestamp.
Additional information: link
DividendDistributor.process(uint256) (#282-306) has costly operations inside a loop:
- currentIndex = 0 (#294)
DividendDistributor.distributeDividend(address) (#313-324) has costly operations inside a loop:
- totalDistributed = totalDistributed.add(amount) (#318)
DividendDistributor.process(uint256) (#282-306) has costly operations inside a loop:
- currentIndex ++ (#303)
Use a local variable to hold the loop computation result.
Additional information: link
BabyMcDollar._maxTxAmount (#370) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 2 / 100
BabyMcDollar._maxWalletToken (#373) is set pre-construction with a non-constant function or state variable:
- (_totalSupply * 3) / 100
BabyMcDollar.swapThreshold (#410) is set pre-construction with a non-constant function or state variable:
- _totalSupply * 10 / 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.4 (#6) 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 BabyMcDollar.swapBack() (#582-626):
- (tmpSuccess) = address(marketingFeeReceiver).call{gas: 30000,value: amountBNBMarketing}() (#610)
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() (#137) is not in mixedCase
Parameter DividendDistributor.setDistributionCriteria(uint256,uint256)._minPeriod (#241) is not in mixedCase
Parameter DividendDistributor.setDistributionCriteria(uint256,uint256)._minDistribution (#241) is not in mixedCase
Variable DividendDistributor._token (#193) is not in mixedCase
Variable DividendDistributor.McdollarReward (#201) is not in mixedCase
Variable DividendDistributor.WBNB (#202) is not in mixedCase
Parameter BabyMcDollar.botTime(bool)._status (#573) is not in mixedCase
Parameter BabyMcDollar.cooldownEnabled(bool,uint8)._status (#577) is not in mixedCase
Parameter BabyMcDollar.cooldownEnabled(bool,uint8)._interval (#577) is not in mixedCase
Parameter BabyMcDollar.setFees(uint256,uint256,uint256,uint256)._liquidityFee (#655) is not in mixedCase
Parameter BabyMcDollar.setFees(uint256,uint256,uint256,uint256)._reflectionFee (#655) is not in mixedCase
Parameter BabyMcDollar.setFees(uint256,uint256,uint256,uint256)._marketingFee (#655) is not in mixedCase
Parameter BabyMcDollar.setFees(uint256,uint256,uint256,uint256)._feeDenominator (#655) is not in mixedCase
Parameter BabyMcDollar.setFeeReceivers(address,address)._autoLiquidityReceiver (#664) is not in mixedCase
Parameter BabyMcDollar.setFeeReceivers(address,address)._marketingFeeReceiver (#664) is not in mixedCase
Parameter BabyMcDollar.setSwapBackSettings(bool,uint256)._enabled (#669) is not in mixedCase
Parameter BabyMcDollar.setSwapBackSettings(bool,uint256)._amount (#669) is not in mixedCase
Parameter BabyMcDollar.setTargetLiquidity(uint256,uint256)._target (#674) is not in mixedCase
Parameter BabyMcDollar.setTargetLiquidity(uint256,uint256)._denominator (#674) is not in mixedCase
Parameter BabyMcDollar.setDistributionCriteria(uint256,uint256)._minPeriod (#679) is not in mixedCase
Parameter BabyMcDollar.setDistributionCriteria(uint256,uint256)._minDistribution (#679) is not in mixedCase
Variable BabyMcDollar.McdollarReward (#360) is not in mixedCase
Variable BabyMcDollar.WBNB (#361) is not in mixedCase
Variable BabyMcDollar.DEAD (#362) is not in mixedCase
Variable BabyMcDollar.ZERO (#363) is not in mixedCase
Constant BabyMcDollar._name (#365) is not in UPPER_CASE_WITH_UNDERSCORES
Constant BabyMcDollar._symbol (#366) is not in UPPER_CASE_WITH_UNDERSCORES
Constant BabyMcDollar._decimals (#367) is not in UPPER_CASE_WITH_UNDERSCORES
Variable BabyMcDollar._totalSupply (#369) is not in mixedCase
Variable BabyMcDollar._maxTxAmount (#370) is not in mixedCase
Variable BabyMcDollar._maxWalletToken (#373) is not in mixedCase
Variable BabyMcDollar._balances (#375) is not in mixedCase
Variable BabyMcDollar._allowances (#376) is not in mixedCase
Follow the Solidity naming convention.
Additional information: link
Variable IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountADesired (#142) is too similar to IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountBDesired (#143)
Prevent variables from having similar names.
Additional information: link
BabyMcDollar.slitherConstructorVariables() (#357-733) uses literals with too many digits:
- DEAD = 0x000000000000000000000000000000000000dEaD (#362)
BabyMcDollar.slitherConstructorVariables() (#357-733) uses literals with too many digits:
- ZERO = 0x0000000000000000000000000000000000000000 (#363)
BabyMcDollar.slitherConstructorVariables() (#357-733) uses literals with too many digits:
- distributorGas = 500000 (#402)
Use: Ether suffix, Time suffix, or The scientific notation
Additional information: link
BabyMcDollar.McdollarReward (#360) is never used in BabyMcDollar (#357-733)
Remove unused state variables.
Additional information: link
BabyMcDollar.DEAD (#362) should be constant
BabyMcDollar.McdollarReward (#360) should be constant
BabyMcDollar.WBNB (#361) should be constant
BabyMcDollar.ZERO (#363) should be constant
BabyMcDollar._totalSupply (#369) should be constant
BabyMcDollar.launchedAt (#398) should be constant
DividendDistributor.WBNB (#202) should be constant
DividendDistributor.dividendsPerShareAccuracyFactor (#215) 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) (#94-96)
unauthorize(address) should be declared external:
- Auth.unauthorize(address) (#101-103)
transferOwnership(address) should be declared external:
- Auth.transferOwnership(address) (#122-126)
botTime(bool) should be declared external:
- BabyMcDollar.botTime(bool) (#573-575)
cooldownEnabled(bool,uint8) should be declared external:
- BabyMcDollar.cooldownEnabled(bool,uint8) (#577-580)
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