PandoraBSC Honeypot
What happened
PandoraBSC (PDRBSC) is a BNB Chain token deployed on 31 May 2021 at 0xd461c271…054798 with a supply of 1 trillion tokens minted to the deployer. Its transfer hook stores one blocked destination in a hidden variable, nxOwner: the first transferFrom call writes its recipient there, and every later transfer to that address fails unless it comes from the owner. When liquidity is added through a router, that first recipient is normally the trading pair, so holders can buy but cannot sell.
A function named transferOwnership does not transfer ownership at all; it lets the owner point the block at any address, and a second owner slot, _leaveowner, keeps the deployer's powers even after renounceOwnership. De.Fi's REKT database lists PandoraBSC as an exit scam and honeypot, describing it as a contract where the owner could stop holders from selling.
How it happened
- The constructor mints the full supply to the deployer:
_balances[msg.sender] = _totalSupply;. - Every transfer runs the
BeforeTransfermodifier. WhilenxOwneris stilladdress(0), the firsttransferFromstores its recipient:if(from != address(0) && nxOwner == address(0) && fromTransfer) nxOwner = to;. A router adding liquidity callstransferFromfrom the owner to the pair, which would make the pair the stored address. - After that, every transfer checks
require((to != nxOwner || from == _owner), "Order TransferFromMiddleware");. A sell sends tokens to the pair, so it reverts for everyone except the owner, while buys (transfers out of the pair) still pass. transferOwnership(address newOwner)only runsnxOwner = newOwner;, so the owner can move the block to any address. The stored address can be read only throughpreviousOwner(), which is itselfonlyOwner.onlyOwneraccepts either_owneror_leaveowner, andrenounceOwnershipclears only_owner. A renounced-looking contract would still let the deployer call owner functions.
Protocol details
Evidence
- report Token Sniffer reply on tokens that block transfers to the LP address (De.Fi proof link) twitter.com
- transaction PandoraBSC contract creation transaction bscscan.com
- address PandoraBSC (PDRBSC) verified contract code on BscScan bscscan.com
- analysis Sourcify match for 0xd461c271f7cf976c6be7762327c4836804054798 on BNB Chain repo.sourcify.dev
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.