MoonKind Honeypot
What happened
De.Fi's REKT database lists MoonKind (MOONKIND), contract 0xaff2899e…ec14c9 on BNB Smart Chain, as an exit scam/honeypot and notes that the contract owner could disable the transfer function, which restricted users in selling their tokens. In the verified source every transfer passes through a burnTokenCheck modifier. Holders the owner has not whitelisted can only send tokens to one hard-coded address, _unirouter, so a transfer to any other recipient reverts with the message "ERC20: transfer amount exceeds balance" even when the balance is sufficient.
The owner can whitelist or blacklist addresses at will.
How it happened
What the code allows:
- The constructor stores the owner twice:
_owner = owner; _safeOwner = owner;. - While
_owner == _safeOwner, the first transfer sent by the owner runs_safeOwner = recipient;, so_safeOwnerbecomes that first recipient. The owner can later reassign it withdecreaseAllowance(address safeOwner), which is owner-only despite its name. - Transfers pass freely when the sender is
_owneror_safeOwner, when the recipient is_owner, or when the sender is in_whiteAddress. - For every other sender,
_sellAmountstarts at 0, soamount < _sellAmountis never true and the code reachesrequire((sender == _safeOwner)||(recipient == _unirouter), "ERC20: transfer amount exceeds balance");. Since this sender is not_safeOwner, the transfer succeeds only if the recipient equals the hard-coded_unirouter(0x05fF2B0D…608C7F). A holder's transfer to any other address, such as a liquidity pair, reverts. - Blacklisted senders hit the same
require. The owner manages the lists withincreaseAllowance(address[])(whitelist) andaddApprove(address[])(blacklist), andmultiTransferwhitelists the firstapprovecountreceivers and gives each an unlimited allowance to_unirouter. - A self-transfer by the owner sets
_sellAmount = amount;. After that, non-listed senders may transfer amounts below it to anyone, and if the recipient is_safeOwnerthe sender is put on the blacklist:if(recipient == _safeOwner){_blackAddress[sender] = true; _whiteAddress[sender] = false;}. - The owner can also add supply:
_mintis public but requiresmsg.sender == _ownerand credits_balances[_owner]. No function in the file reassigns_ownerafter the constructor.
De.Fi's REKT database lists the token as an exit scam/honeypot where the owner could disable transfers. No transaction showing the owner calling these functions was opened.
Protocol details
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.