Fee sharing hook on Ethereum

Uniswap v4 Hook Contract 0xc26462d39b4717cd5f6a67aefd0983f31bd2a888 on Ethereum · Fee sharing

Volume (24h)
$0
Value locked (TVL)
$0
All-time volume
$0
Pools using this hook
1
Swaps (24h)
0 (0 traders)
Total swaps
0

What it does

A fee-sharing hook that enables beforeSwap delta overrides and beforeAddLiquidity gating, routing swaps through an external stableswap-style pool and collecting protocol fees into a token jar.

This read was written for the hook 0xc200…a888 on Ethereum 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

  • Enables beforeInitialize to set an initial stored value for the pool.
  • Gates liquidity additions through beforeAddLiquidity.
  • Overrides swap accounting in beforeSwap using beforeSwapReturnDelta.
  • Routes swap execution through an external Curve-style pool (exchange, get_dy, get_dx).
  • Collects protocol fees and forwards them to a token jar via pollTokenJar.
Swap behaviour
beforeSwap runs custom logic that can return a custom delta, and interacts with an external Curve-style pool via exchange and quote-style calls before settling currency with the PoolManager.
Liquidity behaviour
beforeAddLiquidity is enabled and gated; beforeRemoveLiquidity and afterAddLiquidity/afterRemoveLiquidity are present as selectors but not enabled in permissions, so no liquidity callbacks are active.
Fee behaviour
Protocol fees appear to be collected and routed to a token jar via pollTokenJar and protocolFeeMultiplier/protocolFeeFlags; the hook also appears to route swaps through an external Curve-style pool (exchange, get_dy, get_dx, is_meta), so fees may be partly determined by the external pool.
Owner & admin controls
No verified admin functions found; a storage slot (slot 0, address) is read and written by pollTokenJar and quote, suggesting a configured address (likely token jar or controller) that is set at initialization rather than by an owner setter.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeAddLiquidity, beforeSwap, beforeSwapReturnDelta

beforeInitialize sets an initial value in storage mapping slot 2; beforeAddLiquidity is used to gate or account liquidity additions; beforeSwap runs custom logic and may return a delta (beforeSwapReturnDelta) that bypasses the standard AMM curve, along with quote for price estimation; the hook calls take and settle on the PoolManager to move currency.

Security & trust assessment

Risk level: medium, estimated (decoded bytecode, low confidence).

Who controls it: Behaviour depends on a stored address and a configured fee controller; a privileged key controlling those addresses could redirect protocol fees or change routing, but no explicit owner function was identified.

Risk to user funds: The hook can take and settle currency via the PoolManager during swaps and may return deltas, so it can affect the amounts users receive; it also interacts with an external pool that could affect swap outcomes.

Security findings

  • [medium] Hook moves currency and overrides swap deltas: beforeSwapReturnDelta is enabled and the hook calls take/settle, so the hook can hold or move user and pool currency during swaps.
  • [medium] Dependence on external pool for swap execution: The hook calls external Curve-style pool functions (exchange, get_dy, get_dx), so swap outcomes depend on an external contract that could change or be malicious.
  • [low] Protocol fees routed to external token jar: Bytecode references a token jar and protocol fee controller, so fees collected by the hook are routed to an external address set outside the hook.
  • [info] Unverified source: No verified source is available, so function logic, access control and upgradeability could not be confirmed from the bytecode alone.

Contract details

Verified source
No
Bytecode size
13,893 bytes
Upgradeable proxy
No
Detected patterns
moves-currency, return-delta

Pools using Fee sharing hook