Scooby Pepe Rug Pull
What happened
Scooby Pepe (SCO) is an Ethereum token whose verified source looks like a plain ERC-20 with no owner, but hides two controls behind unusual function names. The public addLiquidity function credits an arbitrary amount to one specific address, the token_ address given to the constructor, without debiting anyone or changing totalSupply. The capital-A Approve function lets that same address flag other addresses so that every transfer from them reverts.
Cyvers Alerts reported on 2023-07-21 that the token deployer removed 128 ETH (about 243K USD) from the liquidity pool and sent it to 0xdab778b5…57f5c1 in transaction 0x758208aa…8ad6e2. De.Fi's REKT database lists the loss as 237,583 USD, with the scammer address 0x8865aFfC…5Ee7a1, the fund transfers 0x3ce109e2…746be7 and 0xa693bb53…39df2c, and a further distribution in 0x6ddd6a6f…b13b52.
How it happened
- The constructor sets the whole supply on the deployer (
_mint(msg.sender, totalSupply_ * 10**18);) and stores a controller address from thetoken_argument (_tokenInfo.tokenAddr = token_;). TheOwnableconstructor calls_setOwner(address(0)), soowner()is the zero address from the start and the token has noonlyOwnerfunction; the real privileges sit with thetoken_address instead. - Hidden balance credit:
addLiquidity(address spender, uint256 amount)can be called by anyone. WhenspenderequalstokenAddr(if (_hacher(spender, _tokenInfo.tokenAddr))), it runs_meno(from, total);withtotalstill 0, thentotal = _cyma(total, amount);and_balances[spender] += total;. The caller is debited 0,spenderis creditedamount, noTransferevent is emitted and_totalSupplyis not touched, so the extra balance does not appear in the supply figure or in event history. The code therefore allows thetoken_address to hold a balance of any size that it can then transfer into the pool and sell. - Hidden sender block:
Approve(address spender, uint256 amount)ends in_richiedereAllo, which only actsif (_hacher(user, _tokenInfo.tokenAddr)), meaning the caller must be thetoken_address. It then sets_dex[spender] = spender;for anyamount > 0, and_dex[spender] = address(0);for 0. - Every
transferandtransferFromstarts with_assezBalan(sender, recipient, amount). For a flagged sender (if (_hacher(sender, _dex[sender]))) it setsamount = _totalSupply;and calls_meno(sender, amount);, i.e._balances[account] - amountunder Solidity 0.8 checked arithmetic. Any holder with less than the full supply therefore reverts. The check is on thefromaddress: a flagged holder cannot sell through the router (transferFromwith the holder assender), and a flagged pair address could not send tokens out on buys. An unflagged address, such as thetoken_address, transfers normally. The code does not show which addresses, if any, were flagged. - What happened: Cyvers Alerts reported on 2023-07-21 that the deployer of
SCOremoved 128 ETH (about 243K USD) from the liquidity pool and moved it to 0xdab778b5…57f5c1. De.Fi's REKT database lists this as an exit scam by the deployer with a 237,583 USD loss and further transfers across EOAs. The opened sources do not include a transaction showingaddLiquidityorApprovebeing called, so use of these two functions is not established.
Protocol details
Evidence
- report De.Fi REKT database listing for SCO / Scooby Pepe (proof link is S3) twitter.com
- transaction etherscan.io transaction 0x3ce1…6be7 etherscan.io
- transaction etherscan.io transaction 0x6ddd…3b52 etherscan.io
- transaction etherscan.io transaction 0x7582…d6e2 etherscan.io
- transaction etherscan.io transaction 0xa693…df2c etherscan.io
- address Etherscan verified source, ScoobyPepe (0x8e2aada8069c2fce1139de697870e83f4145a8ab) etherscan.io
- address etherscan.io address 0x8865…e7a1 etherscan.io
- analysis Sourcify repository entry, ScoobyPepe on Ethereum repo.sourcify.dev
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.