Reading the hook.
The address, the bytecode, then a swap each way through its pool. A few seconds.
v4 hook · Robinhood Chain · block 93,114,055
0xF738…28CC
The eight checks
7 pools use this hook, the first one 45 d ago.
- 01caution
Permissions that touch your moneyThe address enables before swap returns delta, after swap returns delta. The hook is allowed to take; the next two checks measure whether it does.
- 02pass
What it takes from a swapIt takes 1% on top of the pool fee.
- 03n/a
LPs can get outClosed to outside LPs: only the hook's own liquidity is in the pool.
- 04pass
The fee is the feeA fixed fee of 0%, written in the pool key.
- 05caution
No one holds the switchNo owner() but it has setFactory, claimPlatformFees, claimCreatorFees, setFeeRecipient.
- 06pass
The code cannot changeNot a proxy, no DELEGATECALL, no SELFDESTRUCT.
- 07pass
Only the PoolManager can call itEach callback refused a call that did not come from the PoolManager.
- 08pass
Track record7 pools over 45 days.
Measured at block 93,114,055. A hook with an owner or a dynamic fee can behave differently later; scan again before a large trade.
What the address allows
A v4 hook's permissions are the last fourteen bits of its address. The PoolManager calls only what they switch on.
address & 0x3fff0x28cc · 10100011001100
- bit 13Before initialize
- bit 12After initialize
- bit 11Before add liquidity
- bit 10After add liquidity
- bit 9Before remove liquidity
- bit 8After remove liquidity
- bit 7Before swap
- bit 6After swap
- bit 5Before donate
What it did to a real swap
A small swap each way and a liquidity round trip, run through the PoolManager and this hook inside a call that is never sent. The pool fee is expected; anything else missing is the hook.
MCD / MCRIB
fee 0%- Swap MCD → MCRIBhook takes 1.00%
- Swap MCRIB → MCDhook takes 1%
- Add, then remove liquiditydeposit refused: LaunchModeLiquidityLocked
pool 0x8ee61a6ae34e590f20550a3cae5d9aff28c7cd618cd20de2cfc73c3bf2a94b65
Read from the bytecode
- Code size
- 12,212 bytes
- Owner
- none found
- Proxy
- no
- DELEGATECALL
- absent
- SELFDESTRUCT
- absent
- Outside calls
- 9
- Callbacks open to anyone
- none
Its functions, uncensored
Selectors found in the dispatcher, named from the public signature database. Red ones are what an owner usually keeps for itself.
- 0x1d8ef3ef currentFeeBps
- 0x21d0ee70 beforeRemoveLiquidity
- 0x238175f3 WALL_WIDTH_TICKS
- 0x259982e5 beforeAddLiquidity
- 0x2af9febb platformRecipient
- 0x3edaf625 totalNativeFeesAccrued
bit 4
After donate
bit 3Before swap returns deltabit 2After swap returns deltabit 1After add returns deltabit 0After remove returns delta- Before initialize. Runs once, when a pool is created.
- Before add liquidity. Can refuse a deposit, or only let some addresses provide liquidity.
- Before swap. Runs before every swap. On a dynamic-fee pool it can set the fee each time.
- After swap. Runs after every swap.
- Before swap returns delta. Can take part of what you put into a swap, or change how much is swapped.
- After swap returns delta. Can take part of what you get out of every swap.
0x431a9caa MAX_TOTAL_FEE_BPS0x46ca626b TICK_SPACING0x479dfd7b CREATOR_SHARE_BPS0x575e24b4 beforeSwap0x5bb47808 setFactory0x5fa65a04 claimPlatformFees0x6c2bbe7e afterRemoveLiquidity0x6fe7e6eb afterInitialize0x81a7e630 wallThreshold0x91dd7346 unlockCallback0x999b93af quote0x9ba64043 LP_FEE_PIPS0x9f063efc afterAddLiquidity0xaf8d60b5 claimCreatorFees0xb2718659 registerPool0xb47b2fb1 afterSwap0xb5217bb4 pools0xb57f4d9c platformAccrued0xb5fc0ff6 setFeeRecipient0xb6a8b0fa beforeDonate0xbc361ef6 gradTick0xbc3db700 feeDisclosure0xbee7f453 WALL_SHARE_BPS0xc45a0155 unknown0xc4e833ce getHookPermissions0xd8464354 PLATFORM_SHARE_BPS0xdc4c90d3 poolManager0xdc98354e beforeInitialize0xe1b4af69 afterDonate0xe1f1c4a7 BASIS_POINTS