Elon Protocol Honeypot
What happened
ELONPRO (Elon Protocol) is a BEP20 token on BNB Smart Chain whose _approve function only records an allowance when the approving account is one hard-coded address; for every other holder it stores zero. That address matches the contract's on-chain owner and deployer, 0x057bd08f…be7058. Swap routers spend a holder's tokens through transferFrom, which needs a non-zero allowance, so a holder's sell reverts while transfers sent directly by the holder, and any buy that pays out of a pool through transfer, do not touch the allowance logic.
De.Fi's REKT database lists the token as an Exit Scam/Honeypot and says the owner could restrict users from selling; it gives no loss figure.
How it happened
- The constructor mints the whole supply (
_totalSupply = 100000000000000000000, 8 decimals) to the deployer. _approveis the only place allowances are written. It containsif (owner == address(0x057bd08fb31757921efe1907217A415213be7058)) { _allowances[owner][spender] = amount; ... } else { _allowances[owner][spender] = 0;, so anapprovecall from any other holder, includingapprove(router, amount), records an allowance of 0.increaseAllowanceanddecreaseAllowancealso route through_approve, so they cannot raise it either.- A buy needs no holder allowance: the pool pays out with
transfer, which calls_transferand never reads_allowances. - A sell through a router calls
transferFrom(holder, pool, amount). After moving the balance, it runs_approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, "BEP20: transfer amount exceeds allowance")). With the stored allowance at 0,subreverts for anyamountabove zero, which rolls back the whole sell. - The hard-coded address passes the
ifbranch, so its own approvals work normally. The owner can also callmint(uint256 amount), which creates tokens for the owner and raises_totalSupply.
Protocol details
Evidence
- report @Token_Sniffer incident report twitter.com
- address BscScan verified source, Elon Protocol (ELONPRO) bscscan.com
- analysis Sourcify match, chain 56, 0xdc212d09b191a7e6f1a8a74b7f7055ef926896d2 repo.sourcify.dev
- analysis De.Fi REKT database listing for ELONPRO de.fi
- analysis Scam explained: BSC no-approval (cryptot3ddybear blog, 2021-04-08) cryptot3ddybear.gitlab.io
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.