ZELDASWAP Honeypot
What happened
ZELDASWAP (ZELDA) is a BEP-20 token on BNB Chain whose transfer function contains an owner-controlled sell block. Every transfer runs calculateFeesBeforeSend, which reverts with "Error: Can not sell this token" whenever the recipient is flagged in the PanCakeSwapReciever mapping. The owner can flag any address, such as the PancakeSwap pair, with setPanCakeSwapReciever, and nothing in the code limits or locks that setter.
Once the pair is flagged, holders can still buy but any sale into the pool reverts. De.Fi's REKT database lists the token as an exit scam/honeypot; no transaction evidence of losses was found.
How it happened
- The constructor mints 10,000,000,000
ZELDAto the deployer, who is also the owner. - The owner can call
setPanCakeSwapReciever(address, true)on any address. Unlike the fee whitelist setters, this function is not gated bycanWhitelist, sorenounceWhitelistdoes not disable it. - Every
transferandtransferFromgoes through_transfer, which callscalculateFeesBeforeSend. That function reverts with "Error: Can not sell this token" ifPanCakeSwapReciever[recipient]is true. - If the liquidity pair is flagged, a sale, which sends
ZELDAto the pair, reverts for every sender, while buys, which sendZELDAfrom the pair to the buyer, still succeed. - The
txFeesetterseTxFeehas no effect on transfers, becausecalculateFeesBeforeSendalways returns the full amount and a zero fee; the flagged-recipient revert is the only trading control.
Protocol details
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.