LILDOG Honeypot
What happened
LILDOG (LDG) is a BEP-20 token on BNB Smart Chain with a one-address sell block. The contract stores an address called newun, and both transfer and transferFrom revert with "please wait" for any transfer sent to it. The first transferFrom made while newun is empty sets newun to its recipient, and the owner can change it with transfernewun.
De.Fi's REKT database lists LDG as an exit scam / honeypot dated 2021-05-14, describing the owner as able to disable transfers so holders cannot sell; it gives no loss figure.
How it happened
- The constructor mints the full supply to the deployer:
balances[owner] = _totalSupply;. transferFrombegins withif(from != address(0) && newun == address(0)) newun = to;. The firsttransferFromafter deployment therefore stores its recipient asnewunand goes through. The code does not say who that recipient is. The blog post linked by De.Fi describes the same pattern as the liquidity pool being captured when liquidity is first added.- After that,
transferFromtakes theelse require(to != newun, "please wait");branch andtransferrunsrequire(to != newun, "please wait");. Any transfer tonewunreverts, whatever the sender, and the revert comes beforebalances[from]is debited. Ifnewunis a trading pair, selling into it fails while buying from it still works; the source does not show thatnewunis the pair. - The owner can call
transfernewun(address _newun)to setnewunto any address. Setting it to the zero address re-arms the capture, so the nexttransferFromwith a non-zero sender stores a new recipient; pointing it at an address nobody uses lifts the block. - A comment repeated in the source reads "This is a token where you can't sell". The code shows these controls exist in the compiled
TokenBEP20contract; it does not show hownewunwas set or used on-chain.
Protocol details
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.