Reading the hook.
The address, the bytecode, then a swap each way through its pool. A few seconds.
v4 hook · Robinhood Chain · block 93,271,424
0x4663…0088
The eight checks
4 pools use this hook, the first one 66 d ago.
- 01caution
Permissions that touch your moneyThe address enables before 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.00% on top of the pool fee.
- 03pass
LPs can get outLiquidity added and removed in the same block came back whole.
- 04pass
The fee is the feeA fixed fee of 0%, written in the pool key.
- 05caution
No one holds the switchOwned by 0x9D116B03FA6eB7F02c232670Bc083530609c5572. Owner-style functions: setDefaultProtocolFeeBps, transferOwnership.
- 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 record4 pools over 66 days.
Measured at block 93,271,424. 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 & 0x3fff0x0088 · 00000010001000
- 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.
ETH / MOONER
fee 0%- Swap ETH → MOONERhook takes 1.00%
- Swap MOONER → ETHno liquidity above the price
- Add, then remove liquiditycame back whole
pool 0xb3b57975cfd5701ef9f3f2dfcc9153960eb79f8a739bb2ced0c74fd0f93147f4
Read from the bytecode
- Code size
- 10,980 bytes
- Owner
- 0x9D116B03FA6eB7F02c232670Bc083530609c5572
- Proxy
- no
- DELEGATECALL
- absent
- SELFDESTRUCT
- absent
- Outside calls
- 5
- 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.
- 0x013f9d85 unknown
- 0x08b66372 HOOK_FLAGS
- 0x0946ea94 unknown
- 0x0ae89127 tokenOfPool
- 0x0ebb4549 unknown
- 0x13ff9c9d unknown
- 0x1b521395 unknown
bit 4
After donate
bit 3Before swap returns deltabit 2After swap returns deltabit 1After add returns deltabit 0After remove returns delta- Before swap. Runs before every swap. On a dynamic-fee pool it can set the fee each time.
- Before swap returns delta. Can take part of what you put into a swap, or change how much is swapped.
0x21d0ee70
beforeRemoveLiquidity
0x259982e5 beforeAddLiquidity0x477075d8 unknown0x47bd23fc DEFAULT_HOOK_FEE_BPS0x4a366fc6 unknown0x4eb36b5f unknown0x575e24b4 beforeSwap0x5afb5687 setDefaultProtocolFeeBps0x5cffe4c2 unknown0x6c2bbe7e afterRemoveLiquidity0x6fe7e6eb afterInitialize0x79c76e1a flush0x803db96d protocolTreasury0x83f6a3a9 unknown0x8652edf9 poolKeyOf0x8a498cf6 feeReceiver0x8da5cb5b owner0x8f9a7b6f unknown0x927ab99c unknown0x944a020d DEFAULT_PROTOCOL_FEE_BPS0x97412daf unknown0x9f063efc afterAddLiquidity0xa41d3643 unknown0xa7465bdb pairOf0xb2dd5c07 registered0xb47b2fb1 afterSwap0xb5584ed8 unknown0xb630571a validateHookAddress0xb6a8b0fa beforeDonate0xb7fb7ee6 PROTOCOL_FEE_BPS_MAX0xc4e833ce getHookPermissions0xd51b2a5e unknown0xd82af4b5 defaultProtocolFeeBps0xd90389b9 unknown0xdc4c90d3 poolManager0xdc98354e beforeInitialize0xe1b4af69 afterDonate0xeef892c3 unknown0xf097fae6 unknown0xf16ddf7b protocolFeeBps0xf2fde38b transferOwnership