EarnHub Token Token Logo

EHB [EarnHub] Token

About EHB

Listings

Token 2 years
CoinMarketCap 2 years

Website

EarnHub is the first ever modular-ready token, allowing the contract to be upgraded on the blockchain, adding new features like new buy-back systems, auto-balancing staking pools, Play to Earn (P2E) mechanisms, and more. Designed entirely for passive income, EarnHub puts the power in the hands of the holders to optimize and design how they make their money - by choosing a reflection reward in any token on the BInance Smart Chain paired with rewards from staking into the proprietary Mirror Reward Pools, a staking innovation based on volume.

EarnHub is the Native Utility Token That is Used for:

* Gaining yields in a token of the holder's choosing (including EHB)
* Staking into Mirror Pools
* Playing in the Play to Earn gambling platform
* Earning active income via loyalty rewards and referral systems

Laser Scorebeta Last Audit: 2 March 2022

report
Token seems to be a scam (type: rug pull scam).

Anti-Scam

Links


Unable to find manual contract audit (e.g. Certik, PeckShield, Solidity...)


Contract creator or owner is blacklisted for past scams

EarnHub._swapBack() (#438-462) sends eth to arbitrary user
Dangerous calls:
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
Ensure that an arbitrary user cannot withdraw unauthorized funds.

Additional information: link

Reentrancy in EarnHub._transferFrom(address,address,uint256) (#336-391):
External calls:
- _swapBack() (#342)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- loyaltyTracker.getReferralData(_addr) (#517-531)
External calls sending eth:
- _swapBack() (#342)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
State variables written after the call(s):
- _balances[sender] -= amount (#361)
- _balances[recipient] += amountAfterFee (#362)
- amountAfterFee = _takeFee(sender,recipient,amount,transferType,referralBuyDiscount,referralSellDiscount) (#360)
- _balances[address(this)] += feeAmount (#427)
Apply the check-effects-interactions pattern.

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.

Auth.transferOwnership(address).adr (#105) lacks a zero-check on :
- owner = adr (#106)
EarnHub.rescueSquad(address)._to (#611) lacks a zero-check on :
- (success) = _to.call{value: address(this).balance}() (#612)
Check that the address is not zero.

Additional information: link

Reentrancy in EarnHub._swapBack() (#438-462):
External calls:
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
External calls sending eth:
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
Event emitted after the call(s):
- GenericErrorEvent(_swapBack(): transferGateway.depositBNB() Failed) (#459)
- GenericErrorEvent(reason) (#460)
Reentrancy in EarnHub._transferFrom(address,address,uint256) (#336-391):
External calls:
- _swapBack() (#342)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- loyaltyTracker.getReferralData(_addr) (#517-531)
External calls sending eth:
- _swapBack() (#342)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
Event emitted after the call(s):
- GenericErrorEvent(getReferralData(): loyaltyTracker.getReferralData() Failed) (#524)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- GenericErrorEvent(reason) (#525)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- GenericErrorEvent(_transferFrom(): referralSellDiscount > baseSellFee) (#353)
- GenericErrorEvent(_transferFrom(): referralBuyDiscount > baseBuyFee) (#356)
- Transfer(_sender,address(this),feeAmount) (#428)
- amountAfterFee = _takeFee(sender,recipient,amount,transferType,referralBuyDiscount,referralSellDiscount) (#360)
Reentrancy in EarnHub._transferFrom(address,address,uint256) (#336-391):
External calls:
- _swapBack() (#342)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- loyaltyTracker.getReferralData(_addr) (#517-531)
- anyflect.setShares(sender,recipient,balancesSender,balancesRecipient) (#373-378)
External calls sending eth:
- _swapBack() (#342)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
Event emitted after the call(s):
- GenericErrorEvent(_transferFrom(): anyflect.setShares() Failed) (#376)
- GenericErrorEvent(reason) (#377)
Reentrancy in EarnHub._transferFrom(address,address,uint256) (#336-391):
External calls:
- _swapBack() (#342)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- loyaltyTracker.getReferralData(_addr) (#517-531)
- anyflect.setShares(sender,recipient,balancesSender,balancesRecipient) (#373-378)
- transferGateway.onTransfer(transf) (#382-387)
External calls sending eth:
- _swapBack() (#342)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
Event emitted after the call(s):
- GenericErrorEvent(_transferFrom(): transferGateway.onTransfer() Failed) (#385)
- GenericErrorEvent(reason_scope_0) (#386)
- Transfer(sender,recipient,amountAfterFee) (#389)
Reentrancy in EarnHub.constructor(address,ITransferGateway,string,string) (#305-327):
External calls:
- pair = IDEXFactory(router.factory()).createPair(router.WETH(),address(this)) (#319)
Event emitted after the call(s):
- Approval(msg.sender,spender,amount) (#646)
- approve(address(pair),_totalSupply) (#323)
- Approval(msg.sender,spender,amount) (#646)
- approve(_dexRouter,_totalSupply) (#322)
- Transfer(address(0),msg.sender,_totalSupply) (#326)
Reentrancy in EarnHub.getReferralData(address) (#515-535):
External calls:
- loyaltyTracker.getReferralData(_addr) (#517-531)
Event emitted after the call(s):
- GenericErrorEvent(getReferralData(): loyaltyTracker.getReferralData() Failed) (#524)
- GenericErrorEvent(reason) (#525)
Apply the check-effects-interactions pattern.

Additional information: link

EarnHub._takeFee(address,address,uint256,EarnHubLib.TransferType,uint256,uint256) (#422-432) uses timestamp for comparisons
Dangerous comparisons:
- feeAmount > 0 (#426)
EarnHub.getVariableSellFee() (#496-513) uses timestamp for comparisons
Dangerous comparisons:
- variableFeeStartingTimestamp > block.timestamp || variableFeeEndingTimestamp < block.timestamp (#500)
- variableFeeEndingTimestamp < block.timestamp (#501)
- variableFeeStartingTimestamp <= block.timestamp && block.timestamp <= variableFeeEndingTimestamp (#505)
Avoid relying on block.timestamp.

Additional information: link

Reentrancy in EarnHub.setAnyflect(IAnyflect) (#560-568):
External calls:
- anyflect.setExcludedFrom(pair,true) (#562)
- anyflect.setExcludedTo(pair,true) (#563)
- anyflect.setExcludedFrom(address(this),true) (#564)
- anyflect.setExcludedFrom(address(0),true) (#565)
- anyflect.setExcludedFrom(0x000000000000000000000000000000000000dEaD,true) (#566)
State variables written after the call(s):
- _authorize(address(anyflect)) (#567)
- authorizations[adr] = true (#79)
Apply the check-effects-interactions pattern.

Additional information: link

EarnHub._transferFrom(address,address,uint256).isReferral (#346) is a local variable never initialized
EarnHub._transferFrom(address,address,uint256).referralCount (#349) is a local variable never initialized
EarnHub.getReferralData(address).referralCount_scope_3 (#517) is a local variable never initialized
EarnHub.getReferralData(address).isReferral_scope_0 (#517) is a local variable never initialized
EarnHub._transferFrom(address,address,uint256).referralBuyDiscount (#347) is a local variable never initialized
EarnHub.getReferralData(address).referralBuyDiscount_scope_1 (#517) is a local variable never initialized
EarnHub._transferFrom(address,address,uint256).reason (#375) is a local variable never initialized
EarnHub._transferFrom(address,address,uint256).reason_scope_0 (#384) is a local variable never initialized
EarnHub._transferFrom(address,address,uint256).referralSellDiscount (#348) is a local variable never initialized
EarnHub._swapBack().reason (#458) is a local variable never initialized
EarnHub.getReferralData(address).reason (#523) is a local variable never initialized
EarnHub.getReferralData(address).referralSellDiscount_scope_2 (#517) is a local variable never initialized
Initialize all the variables. If a variable is meant to be initialized to zero, explicitly set it to zero to improve code readability.

Additional information: link

EarnHub.getReferralData(address) (#515-535) ignores return value by loyaltyTracker.getReferralData(_addr) (#517-531)
Ensure that all the return values of the function calls are used.

Additional information: link

EarnHub.constructor(address,ITransferGateway,string,string)._name (#305) shadows:
- EarnHub._name (#273) (state variable)
EarnHub.constructor(address,ITransferGateway,string,string)._symbol (#305) shadows:
- EarnHub._symbol (#274) (state variable)
Rename the local variables that shadow another component.

Additional information: link

EarnHub.setVariableSellFeeParams(uint256,bool,uint256,uint256) (#539-546) should emit an event for:
- maxSellFee = _maxSellFee (#543)
- variableFeeEndingTimestamp = _endingTimestamp (#545)
- variableFeeStartingTimestamp = block.timestamp (#544)
- variableFeeStartingTimestamp = _startingTimestamp (#544)
EarnHub.setNewBaseFees(uint256,uint256,uint256) (#548-553) should emit an event for:
- baseSellFee = _newBaseSellFee (#550)
- transferFee = _newTransferFee (#551)
- baseBuyFee = _newBaseBuyFee (#552)
EarnHub.setSwapThreshold(uint256) (#595-597) should emit an event for:
- _swapThreshold = _amount (#596)
Emit an event for critical parameter changes.

Additional information: link

Variable 'EarnHub._transferFrom(address,address,uint256).reason_scope_0 (#384)' in EarnHub._transferFrom(address,address,uint256) (#336-391) potentially used before declaration: GenericErrorEvent(reason_scope_0) (#386)
Variable 'EarnHub._transferFrom(address,address,uint256).reason (#375)' in EarnHub._transferFrom(address,address,uint256) (#336-391) potentially used before declaration: GenericErrorEvent(reason) (#377)
Variable 'EarnHub._swapBack().reason (#458)' in EarnHub._swapBack() (#438-462) potentially used before declaration: GenericErrorEvent(reason) (#460)
Variable 'EarnHub.getReferralData(address).isReferral_scope_0 (#517)' in EarnHub.getReferralData(address) (#515-535) potentially used before declaration: isReferral_scope_0 = isReferral_scope_0 (#518)
Variable 'EarnHub.getReferralData(address).referralBuyDiscount_scope_1 (#517)' in EarnHub.getReferralData(address) (#515-535) potentially used before declaration: referralBuyDiscount_scope_1 = referralBuyDiscount_scope_1 (#519)
Variable 'EarnHub.getReferralData(address).referralSellDiscount_scope_2 (#517)' in EarnHub.getReferralData(address) (#515-535) potentially used before declaration: referralSellDiscount_scope_2 = referralSellDiscount_scope_2 (#520)
Variable 'EarnHub.getReferralData(address).referralCount_scope_3 (#517)' in EarnHub.getReferralData(address) (#515-535) potentially used before declaration: referralCount_scope_3 = referralCount_scope_3 (#521)
Variable 'EarnHub.getReferralData(address).reason (#523)' in EarnHub.getReferralData(address) (#515-535) potentially used before declaration: GenericErrorEvent(reason) (#525)
Move all variable declarations prior to any usage of the variable, and ensure that reaching a variable declaration does not depend on some conditional if it is used unconditionally.

Additional information: link

Reentrancy in EarnHub._transferFrom(address,address,uint256) (#336-391):
External calls:
- _swapBack() (#342)
- router.swapExactTokensForETHSupportingFeeOnTransferTokens(amountToSwap,0,path,address(this),block.timestamp) (#446-452)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
- (isReferral,referralBuyDiscount,referralSellDiscount,referralCount) = getReferralData(sender) (#351)
- loyaltyTracker.getReferralData(_addr) (#517-531)
External calls sending eth:
- _swapBack() (#342)
- transferGateway.depositBNB{value: amountBNB}() (#456-461)
State variables written after the call(s):
- amountAfterFee = _takeFee(sender,recipient,amount,transferType,referralBuyDiscount,referralSellDiscount) (#360)
- currentSellFee = baseSellFee (#503)
- currentSellFee = sellFee (#509)
- amountAfterFee = _takeFee(sender,recipient,amount,transferType,referralBuyDiscount,referralSellDiscount) (#360)
- maxSellFee = 0 (#501)
- user = _createOrUpdateUser(address(sender),block.timestamp,isReferral,referralBuyDiscount,referralSellDiscount,referralCount) (#364)
- users[_addr] = user (#396)
Reentrancy in EarnHub.constructor(address,ITransferGateway,string,string) (#305-327):
External calls:
- pair = IDEXFactory(router.factory()).createPair(router.WETH(),address(this)) (#319)
State variables written after the call(s):
- _allowances[address(this)][address(router)] = _totalSupply (#321)
- approve(_dexRouter,_totalSupply) (#322)
- _allowances[msg.sender][spender] = amount (#645)
- approve(address(pair),_totalSupply) (#323)
- _allowances[msg.sender][spender] = amount (#645)
- _balances[msg.sender] = _totalSupply (#325)
- liquidityPairs[pair] = true (#320)
Apply the check-effects-interactions pattern.

Additional information: link

EarnHub.currentSellFee (#257) is set pre-construction with a non-constant function or state variable:
- baseSellFee
EarnHub._maxTxAmount (#277) is set pre-construction with a non-constant function or state variable:
- _totalSupply
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.8.0 (#2) allows old versions
solc-0.8.0 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 EarnHub.rescueSquad(address) (#611-614):
- (success) = _to.call{value: address(this).balance}() (#612)
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() (#160) is not in mixedCase
Parameter EarnHub.getLiquidityBacking(uint256)._accuracy (#470) is not in mixedCase
Parameter EarnHub.isOverLiquified(uint256,uint256)._target (#474) is not in mixedCase
Parameter EarnHub.isOverLiquified(uint256,uint256)._accuracy (#474) is not in mixedCase
Parameter EarnHub.getTotalFee(EarnHubLib.TransferType,uint256,uint256)._transferType (#478) is not in mixedCase
Parameter EarnHub.getTotalFee(EarnHubLib.TransferType,uint256,uint256)._referralBuyDiscount (#478) is not in mixedCase
Parameter EarnHub.getTotalFee(EarnHubLib.TransferType,uint256,uint256)._referralSellDiscount (#478) is not in mixedCase
Parameter EarnHub.getReferralData(address)._addr (#515) is not in mixedCase
Parameter EarnHub.setVariableSellFeeParams(uint256,bool,uint256,uint256)._maxSellFee (#539) is not in mixedCase
Parameter EarnHub.setVariableSellFeeParams(uint256,bool,uint256,uint256)._useCurrentTimestampForStart (#539) is not in mixedCase
Parameter EarnHub.setVariableSellFeeParams(uint256,bool,uint256,uint256)._startingTimestamp (#539) is not in mixedCase
Parameter EarnHub.setVariableSellFeeParams(uint256,bool,uint256,uint256)._endingTimestamp (#539) is not in mixedCase
Parameter EarnHub.setNewBaseFees(uint256,uint256,uint256)._newBaseSellFee (#548) is not in mixedCase
Parameter EarnHub.setNewBaseFees(uint256,uint256,uint256)._newTransferFee (#548) is not in mixedCase
Parameter EarnHub.setNewBaseFees(uint256,uint256,uint256)._newBaseBuyFee (#548) is not in mixedCase
Parameter EarnHub.setTransferGateway(ITransferGateway)._transferGateway (#555) is not in mixedCase
Parameter EarnHub.setAnyflect(IAnyflect)._anyflect (#560) is not in mixedCase
Parameter EarnHub.setDexRouter(IDEXRouter)._router (#570) is not in mixedCase
Parameter EarnHub.setLoyaltyTracker(ILoyaltyTracker)._loyaltyTracker (#574) is not in mixedCase
Parameter EarnHub.setTxLimit(uint256)._amount (#579) is not in mixedCase
Parameter EarnHub.setIsFeeExempt(address,bool)._addr (#583) is not in mixedCase
Parameter EarnHub.setIsFeeExempt(address,bool)._exempt (#583) is not in mixedCase
Parameter EarnHub.setIsTxLimitExempt(address,bool)._addr (#587) is not in mixedCase
Parameter EarnHub.setIsTxLimitExempt(address,bool)._exempt (#587) is not in mixedCase
Parameter EarnHub.setLiquidityPair(address,bool)._pair (#591) is not in mixedCase
Parameter EarnHub.setLiquidityPair(address,bool)._value (#591) is not in mixedCase
Parameter EarnHub.setSwapThreshold(uint256)._amount (#595) is not in mixedCase
Parameter EarnHub.setAnyflectExempt(address,bool)._addr (#599) is not in mixedCase
Parameter EarnHub.setAnyflectExempt(address,bool)._value (#599) is not in mixedCase
Parameter EarnHub.setPresaleContract(address,bool)._addr (#603) is not in mixedCase
Parameter EarnHub.setPresaleContract(address,bool)._value (#603) is not in mixedCase
Parameter EarnHub.setBasicTransfer(address,bool)._addr (#607) is not in mixedCase
Parameter EarnHub.setBasicTransfer(address,bool)._value (#607) is not in mixedCase
Parameter EarnHub.rescueSquad(address)._to (#611) is not in mixedCase
Parameter EarnHub.fuckShitcoins(IBEP20,address[],address)._shitcoin (#617) is not in mixedCase
Parameter EarnHub.fuckShitcoins(IBEP20,address[],address)._path (#617) is not in mixedCase
Parameter EarnHub.fuckShitcoins(IBEP20,address[],address)._to (#617) is not in mixedCase
Constant EarnHub._name (#273) is not in UPPER_CASE_WITH_UNDERSCORES
Constant EarnHub._symbol (#274) is not in UPPER_CASE_WITH_UNDERSCORES
Constant EarnHub._decimals (#275) is not in UPPER_CASE_WITH_UNDERSCORES
Variable EarnHub._totalSupply (#276) is not in mixedCase
Variable EarnHub._maxTxAmount (#277) is not in mixedCase
Variable EarnHub._swapThreshold (#278) is not in mixedCase
Variable EarnHub._balances (#280) is not in mixedCase
Variable EarnHub._allowances (#281) is not in mixedCase
Follow the Solidity naming convention.

Additional information: link

Variable IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountADesired (#165) is too similar to IDEXRouter.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountBDesired (#166)
Prevent variables from having similar names.

Additional information: link

EarnHub.setAnyflect(IAnyflect) (#560-568) uses literals with too many digits:
- anyflect.setExcludedFrom(0x000000000000000000000000000000000000dEaD,true) (#566)
EarnHub.slitherConstructorVariables() (#249-658) uses literals with too many digits:
- deadAddress = 0x000000000000000000000000000000000000dEaD (#253)
Use: Ether suffix, Time suffix, or The scientific notation

Additional information: link

EarnHub._totalSupply (#276) should be constant
EarnHub.deadAddress (#253) should be constant
Add the constant attributes to state variables that never change.

Additional information: link

unauthorize(address) should be declared external:
- Auth.unauthorize(address) (#84-86)
transferOwnership(address) should be declared external:
- Auth.transferOwnership(address) (#105-109)
isOverLiquified(uint256,uint256) should be declared external:
- EarnHub.isOverLiquified(uint256,uint256) (#474-476)
Use the external attribute for functions never called from the contract.

Additional information: link

Holders:


Average 30d PancakeSwap liquidity is less than $100. Token is either dead or inactive.


Average 30d PancakeSwap volume is less than $100. Token is either dead or inactive.


Average 30d number of PancakeSwap swaps is less than 1. Token is either dead or inactive.


Average PancakeSwap trading volume, liqudity, number of swaps are extremely low. Token seems to be dead.

Contract has 11% buy tax and 0% sell tax.
Taxes are high (over 10%) but contract ownership is renounced.


Swap operations require suspiciously high gas. Contract logic is complex and may disguise some form of scam.


Token is deployed only at one blockchain


Token has only one trading pair


Twitter account link seems to be invalid


Unable to crawl data from the website


BscScan page for the token does not contain additional info: website, socials, description, etc.

Additional information: link


Unable to find token/project description on the website or on BscScan, CoinMarketCap


Unable to find token contract audit


Unable to find audit link on the website


Unable to find whitepaper link on the website


Unable to find Telegram link on the website


Unable to find Twitter link on the website


Unable to find code repository for the project


Token is marked as scam (rug pull, honeypot, phishing, etc.)

Additional information: link


Young tokens have high risks of price dump / death


Young tokens have high risks of scam / price dump / death


Young tokens have high risks of price dump / death


Token has relatively low CoinGecko rank


Token has relatively low CoinMarketCap rank

Price for EHB