Dynamic fee hook on Robinhood Chain
Uniswap v4 Hook Contract 0x0676d18db3a12bbec030782b6c873d251d46d000 on Robinhood Chain · Dynamic fee
- Volume (24h)
- $2.85
- Value locked (TVL)
- $51
- All-time volume
- $2.85
- Pools using this hook
- 1
- Swaps (24h)
- 3 (3 traders)
- Total swaps
- 3
What it does
This hook sets a keeper-controlled dynamic LP fee on one pool, so traders pay whatever fee the keeper last set, and the admin can pause trading entirely; which trade direction pays more is not determinable from the bytecode.
How it works step by step
- Sets a dynamic LP fee for the pool through a keeper-controlled updateDynamicLPFee call on the pool manager, starting from a constant INITIAL_FEE.
- Stores a single bound pool id and pool key, and rejects calls that reference a different pool (UnexpectedPoolKey).
- Tracks a keeper address that is the only role allowed to change the fee configuration, separate from the admin role.
- Can be paused and unpaused by admin; while paused, pool interactions guarded by the hook revert with IsPaused.
- Uses a two-step admin transfer (transferAdmin then acceptAdmin) with pending admin tracking.
- Swap behaviour
- beforeSwap and afterSwap are exposed as selectors and are view-style checks; the hook does not take tokens or alter swap amounts, so the fee applied on swaps is whatever the keeper last set via the dynamic fee mechanism. Which trade direction pays more cannot be determined from the decoded bytecode.
- Liquidity behaviour
- Before and after add and remove liquidity callbacks are present as view-style selectors that do not move funds; they appear to be pass-through checks, and the hook does not take liquidity-specific fees from the decoded code.
- Fee behaviour
- The LP fee is set dynamically through updateDynamicLPFee on the pool manager, with the current value readable via currentFee and a starting value of INITIAL_FEE; setFee-style updates require the keeper role and revert with FeeUnchanged if the value is identical. The exact fee formula or range cannot be determined from decoded bytecode.
- Owner & admin controls
- Admin can pause and unpause the hook, transfer the admin role via a two-step process, and set the keeper address. Keeper can update the dynamic fee and a uint24 fee setter is callable by the keeper or admin. No upgradeability pattern was observed.
Enabled Uniswap v4 callbacks
afterInitialize
afterInitialize is the only enabled hook permission; it runs once after pool initialization to bind the pool and set the initial fee. Other callbacks are present as selectors but are not enabled by the address permissions.
Security & trust assessment
Risk level: medium, estimated (decoded bytecode, medium confidence).
Who controls it: A single admin key can pause the hook, change the keeper and transfer admin; the keeper can set the pool fee to any value the pool manager accepts, so these keys can directly affect trader costs and halt trading.
Risk to user funds: The hook does not appear to hold or move user tokens through return deltas; its exposure is indirect, via fee manipulation and pausing that can block or reprice swaps and liquidity actions.
Security findings
- [medium] Keeper controls the pool fee: The keeper can call the fee-update path via updateDynamicLPFee, so a compromised or malicious keeper could set an arbitrary LP fee on the bound pool, affecting all swappers.
- [medium] Pausable hook: The admin can pause the hook, which causes guarded callbacks to revert with IsPaused, potentially blocking swaps or liquidity actions on the pool while paused.
- [low] Admin key can reassign keeper: setKeeper is callable by the admin, so the admin can replace the keeper and gain control over fee-setting power indirectly.
- [info] Fee range not verified: Without source, the maximum allowed fee and any bounds on keeper changes could not be confirmed from the bytecode.
Contract details
- Verified source
- No
- Bytecode size
- 6,531 bytes
- Upgradeable proxy
- No
- Detected patterns
- dynamic-fee, pausable
Pools using Dynamic fee hook
- ETH / USDG (Dynamic fee) — 24h volume $2.85, TVL $51, 3 swaps today