Fee sharing hook on Robinhood Chain
Uniswap v4 Hook Contract 0x9ab08e4a2c37540c4b79f666192e1ec86fd800c4 on Robinhood Chain · Fee sharing
- Volume (24h)
- $0
- Value locked (TVL)
- <$0.01
- All-time volume
- $14.43M
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 14,247
What it does
A Uniswap v4 hook that applies custom fee configuration and a configurable LP fee share on swaps, with an owner-controlled pause and withdrawal functions.
How it works step by step
- Reads a packed fee configuration (multiple uint24 and uint16 fields) stored in slot 2 and applies it on swaps
- Counts swaps per pool in a mapping keyed by pool id (slot 3)
- Returns a delta from afterSwap, so it can take a portion of swap output or input
- Splits part of the swap fee to LPs according to lpFeeShareBps (uint16 in slot 0)
- Can be paused by the owner to halt swap processing
- Lets the owner withdraw or sweep tokens the hook has accumulated
- Swap behaviour
- beforeSwap checks pause state and fee configuration and tracks per-pool swap counts; afterSwap computes the LP fee share and uses the return-delta permission to adjust the swap's settled amounts.
- Liquidity behaviour
- beforeAddLiquidity, afterAddLiquidity, beforeRemoveLiquidity and afterRemoveLiquidity selectors are present, but the decoded bytecode does not show evidence of substantive custom logic in them beyond the callback entry points.
- Fee behaviour
- A fee configuration is stored in slot 2 (several uint24 and uint16 fields) and read during swaps; an owner-settable setter (0x65a08c0e) updates it. The hook also keeps an LP fee share in basis points (lpFeeShareBps) which is read in afterSwap, indicating a portion of swap-derived fees is routed to LPs or accounted separately. Exact fee split logic cannot be confirmed without source.
- Owner & admin controls
- Owner (slot 0 address) can transfer ownership, pause and unpause the hook via setPaused, set the LP fee share via setLpFeeShareBps (uint16), set fee configuration via the 0x65a08c0e setter with seven parameters, sweep tokens via sweep(address), and withdraw funds via withdraw(address,address,uint256). Owner is the only privileged role identified from the selectors.
Enabled Uniswap v4 callbacks
beforeSwap, afterSwap, afterSwapReturnDelta
beforeSwap: runs pre-swap logic, including reading fee configuration and pause state and recording swap data. afterSwap: runs post-swap accounting, reads the LP fee share, and uses afterSwapReturnDelta to take or return a delta from the swap. beforeSwap and afterSwap are the active swap hooks; the return-delta flag means the hook can alter the amounts settled with the PoolManager.
Security & trust assessment
Risk level: high (decoded bytecode, medium confidence).
Who controls it: A single owner key controls pausing, fee configuration, LP fee share, token sweeping and withdrawals. A compromised or malicious owner could drain any tokens held by the hook, change fees arbitrarily, or halt swaps by pausing.
Risk to user funds: Tokens held by the hook (including any fee or delta balances) can be withdrawn or swept by the owner. Swaps can be blocked by pausing. Users' pool liquidity is not directly controlled by the hook's liquidity callbacks, which appear passive.
Security findings
- [high] Owner can withdraw and sweep hook-held funds: withdraw(address,address,uint256) and sweep(address) allow the owner to move tokens held by the hook contract.
- [medium] Owner can pause swaps: setPaused(bool) is callable by the owner and paused() is checked in swap logic, so the owner can block swaps at will.
- [medium] Owner can change fee parameters: The fee configuration setter (0x65a08c0e) and setLpFeeShareBps(uint16) let the owner change fee parameters without a timelock visible in the bytecode.
- [medium] Return delta can alter swap settlement: Hook uses afterSwapReturnDelta, so it can take or return token amounts from swaps, affecting the net settlement with the PoolManager.
- [info] Single-step ownership transfer: Ownable with transferOwnership(address) and no evident two-step transfer or renounce protection in the selectors; a mistaken transfer would be permanent.
Contract details
- Verified source
- No
- Bytecode size
- 8,629 bytes
- Upgradeable proxy
- No
- Detected patterns
- ownable, pausable, return-delta
Pools using Fee sharing hook
- ETH / USDG (Dynamic fee) — 24h volume $0, TVL <$0.01, 0 swaps today