Fee sharing hook on BNB Chain

Uniswap v4 Hook Contract 0x920f533753ccb5f8af0f4e72894b208cbb45c044 on BNB Chain · Fee sharing

Volume (24h)
$0
Value locked (TVL)
$0
All-time volume
$8.66M
Pools using this hook
2
Swaps (24h)
0 (0 traders)
Total swaps
7,108

What it does

A fee-sharing hook that takes a tiered fee from swaps after they execute and routes the fee to a configurable recipient, tracking swap counts per pool.

How it works step by step

  • Records a swap count per pool id in a mapping after each swap
  • Applies a tiered fee (tier one, two and three fees) based on pool or swap conditions
  • Uses afterSwapReturnDelta to take the fee from the swap output
  • Forwards collected fees to a configurable recipient address
  • Exposes a gas threshold and fee denominators used in fee calculation
  • Owner can update the recipient, fee config and withdraw balances
Swap behaviour
After each swap, the hook computes a tiered fee, takes it as a return delta, and increments a per-pool swap counter; the beforeSwap selector is present but no distinct pre-swap logic was identified.
Liquidity behaviour
Liquidity add and remove callbacks (beforeAddLiquidity, afterAddLiquidity, beforeRemoveLiquidity, afterRemoveLiquidity) are exposed as view-style selectors; no clear state-changing liquidity logic was identified, so this is likely pass-through.
Fee behaviour
Fees are tiered (tierOne, tierTwo, tierThree fees and a gas threshold) with a configurable fee config and a fee recipient; the hook appears to take a share of swap output via afterSwap return deltas, but the exact tier selection logic cannot be fully confirmed without source.
Owner & admin controls
Owner (slot 0) can call setRecipient(address) to change the fee recipient, transferOwnership(address) to hand over ownership, withdraw(address,address,uint256) to pull tokens out of the hook, and a 24d64c99 setter that writes fee tier values and thresholds (fee tiers, gas threshold, tier parameters).

Enabled Uniswap v4 callbacks

afterSwap, afterSwapReturnDelta

afterSwap: records swap activity per pool (swapCount mapping) and applies fee logic after each swap. afterSwapReturnDelta: lets the hook take a token amount from swap output and route it to the recipient as protocol or hook fee.

Security & trust assessment

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

Who controls it: The owner controls the fee recipient and fee parameters and can withdraw tokens held by the hook, so a compromised owner key could redirect fees or drain balances held by the hook contract.

Risk to user funds: The hook takes a share of swap output via return deltas and holds fee balances that the owner can withdraw; user LP principal sits in the pool manager rather than the hook, so exposure is mainly to swap fee amounts and any balances accumulated in the hook.

Security findings

  • [medium] Owner-controlled withdrawal of hook balances: withdraw(address,address,uint256) is callable by the owner and moves tokens out of the hook; any accumulated fee balances are controlled by the owner key.
  • [medium] Owner can change fee parameters: Fee tiers and the gas threshold are writable by the owner, so the fee taken from swaps can be raised by the owner at any time.
  • [info] Hook takes tokens via return delta: afterSwapReturnDelta lets the hook take a portion of swap output, so the hook directly affects the amounts traders receive.
  • [low] Single-key ownership: Ownership is a single address in slot 0 with transferOwnership and no evident timelock or multisig requirement in the bytecode.

Contract details

Verified source
No
Bytecode size
7,889 bytes
Upgradeable proxy
No
Detected patterns
ownable, return-delta

Pools using Fee sharing hook