Likely custom pricing hook on Robinhood Chain
Uniswap v4 Hook Contract 0x20d1efda0ae059897820833221946c7af78565c7 on Robinhood Chain · Custom pricing
- Volume (24h)
- $0
- Value locked (TVL)
- <$0.01
- All-time volume
- $0
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 0
What it does
An upgradeable, admin-controlled hook that takes a buy/sell tax from swap output and sends it to a collector, and gates and can alter LP deposits and withdrawals through a whitelist.
This read was written for the hook 0x0610…a5c7 on Base and reused here: the two share a code shape, so constants such as fees, owners and addresses can differ.
How it works step by step
- Charges a buy/sell tax on swaps in its pools, with a hard-coded maximum tax constant whose exact value cannot be read from bytecode alone.
- Sends collected tax to a collector address that the admin can change.
- Keeps an LP whitelist, so adding and removing liquidity can be restricted to approved addresses.
- Runs on liquidity adds and removals and can adjust the amounts LPs receive or pay through return deltas.
- Runs behind an upgradeable proxy, so the admin can replace the logic at any time.
- Swap behaviour
- Before and after each swap the hook applies a configurable tax, which can be set separately for buys and sells. It can take that tax out of the swap output through its after-swap return delta.
- Liquidity behaviour
- Adding and removing liquidity trigger the hook, which checks an LP whitelist and can change the amounts settled for LPs. Because the remove-liquidity callback and its return delta are enabled and the code is upgradeable, withdrawals could be blocked or charged.
- Fee behaviour
- The swap tax is set in basis points, likely with separate buy and sell rates, and is capped by a built-in maximum tax constant that is not visible in the decoded data. Taxes go to an admin-set collector address.
- Owner & admin controls
- The admin can set tax rates up to the built-in maximum, change the collector, manage the LP whitelist, change other config values and transfer the admin role. The proxy can also be upgraded to new logic.
Enabled Uniswap v4 callbacks
beforeInitialize, afterAddLiquidity, afterRemoveLiquidity, beforeSwap, afterSwap, afterSwapReturnDelta, afterAddLiquidityReturnDelta, afterRemoveLiquidityReturnDelta
beforeInitialize: sets up and validates the pool; afterAddLiquidity / afterRemoveLiquidity: enforce the LP whitelist and adjust LP amounts; beforeSwap: computes the tax and checks config; afterSwap with return delta: takes the tax from swap output; liquidity return deltas: can modify what LPs pay or receive.
Security & trust assessment
Risk level: high, estimated (decoded bytecode, medium confidence).
Who controls it: A single admin controls tax rates, the collector, the LP whitelist and the proxy implementation. The worst case is an upgrade that takes swap output or traps LP funds.
Risk to user funds: Swap output can be reduced by the tax, up to an unknown built-in maximum. LP add and remove amounts can be altered, so LP principal could be locked or charged under the current whitelist rules or after an upgrade.
Security findings
- [high] Upgradeable proxy with fund-moving permissions: The hook is an upgradeable proxy whose address enables the swap and liquidity return deltas and the after-remove-liquidity callback. A new implementation could take swap tokens or block or charge LP withdrawals.
- [medium] LP whitelist on liquidity actions: A whitelist mapping is checked during liquidity adds and removals. Non-whitelisted addresses may be blocked.
- [medium] Adjustable swap tax: The admin can change buy and sell tax rates up to a hard-coded maximum. That maximum's value is not readable from the decoded bytecode.
Contract details
- Verified source
- No
- Bytecode size
- 45 bytes
- Upgradeable proxy
- Yes
- Detected patterns
- return-delta
Pools using Likely custom pricing hook
- USDG / VISTA (0.01% fee) — 24h volume $0, TVL <$0.01, 0 swaps today