Terk The Gorilla Rug Pull
What happened
Terk The Gorilla (TERK) was an ERC-20 token on Ethereum traded against WETH on Uniswap V3. On 2023-07-26, the day after deployment, the deployer 0x82d8eE74…fDEd92 removed the pool's liquidity, taking about 65.36 WETH and about 23.1 billion TERK (tx 0x4358608c…4bd1b3); De.Fi puts the loss at $122,440 (65.35 ETH) and Cyvers at about $121K. The funds then moved through other addresses, and on 2023-07-27 60 ETH were split into ten 6 ETH payments with the CoinTool MultiSender (tx 0x0a8f1862…d8bf6f).
The token code also hides extra controls behind misleading names: owner() is zero from deployment, so the contract looks renounced, but a separate address stored at deployment, 0xEA2d426D…5153A2, can credit itself any amount of TERK through the public addLiquidity function and can freeze any holder through Approve (capital A). No opened source shows whether those two functions were used.
How it happened
- The constructor mints 33,333,333,333
TERKto the deployer and stores the constructor argumenttoken_as_tokin.addr. Etherscan decodes that argument as 0xEA2d426D…5153A2. Ownable's constructor runs_setOwner(address(0)), soowner()returns zero from the start and the token appears ownerless. The real privileges are keyed to_tokin.addrinstead.- Hidden mint:
addLiquidity(lxpatok, amot, canTrad)is public. Whenlxpatokequals_tokin.addr, it runstotal = _cosum(total, amot); _balances[lxpatok] += total;while subtracting 0 from the caller, so_tokin.addrcan be credited any amount withouttotalSupplychanging. Other targets receive nothing. - Hidden blacklist:
Approve(xpenter, xamot)checks_encry(uxe, _tokin.addr), so only_tokin.addrcan use it; it sets_detxex[xpenter] = xpenterfor a nonzero amount, or clears the flag for zero. - Every
transferandtransferFromfirst calls_rexBaxlat(sender, ...). For a flagged sender it runstamou = _totSut; _minut(sender, tamou);, subtracting the whole total supply from the sender's balance. Under Solidity 0.8.4 checked arithmetic that underflows and reverts, so a flagged holder cannot sell or move tokens. - What happened on 2023-07-26: the deployer closed its Uniswap V3 position and received about 65.36 WETH and about 23.1 billion
TERK(tx 0x4358608c…4bd1b3). The pull used the standard Uniswap V3 position manager, not the hidden functions.
Protocol details
Evidence
- report Cyvers Alerts on the $TERK liquidity removal twitter.com
- transaction Etherscan transaction 0x4358608c... (Uniswap V3 liquidity removal) etherscan.io
- transaction Etherscan transaction 0x0a8f1862... (CoinTool MultiSender) etherscan.io
- address Terk The Gorilla (TERK) verified contract source and constructor arguments, Etherscan etherscan.io
- address etherscan.io address 0x82d8…Ed92 etherscan.io
- analysis Sourcify exact match, chain 1, 0xea05110ce800719cc041e5fe79490af0d94d803f repo.sourcify.dev
Build your security review skills
Work through hands-on labs covering real exploit mechanics, review techniques, and defensive patterns.