Rewards hook on Ethereum
Uniswap v4 Hook Contract 0x95e0186cb94a4d6e51beb88edd26b43140b4a0c4 on Ethereum · Rewards
- Volume (24h)
- $1.24K
- Value locked (TVL)
- $0
- All-time volume
- $1.24K
- Pools using this hook
- 1
- Swaps (24h)
- 17 (14 traders)
- Total swaps
- 17
What it does
This hook takes a cut of swaps through afterSwap return deltas, accumulates it into reward pots and splits it between a treasury and staking, so traders receive slightly less output while the owner controls where that value goes.
How it works step by step
- Tracks a set of currencies per pool, registering each currency address in an array when the pool is initialized.
- Accumulates per-currency reward or pot balances in a nested mapping updated during afterSwap.
- Uses return deltas in afterSwap to take a portion of swap output into hook-held accounting.
- Splits accumulated funds between a treasury and staking-related destinations according to owner-configured splits and a burn rate.
- Mints and burns ERC6909 claim tokens to represent hook-held balances and settles matches between factions in settleMatch.
- Calls back into the pool manager through unlock and unlockCallback to settle and take currency during accounting operations.
- Swap behaviour
- afterSwap updates reward and pot accounting for the swapped currencies and can take a share of the swap via its return delta, so affected swappers receive slightly less output than the pool price alone implies. beforeSwap is also exposed by the hook but its effect cannot be determined from the decoded bytecode beyond its dispatch.
- Liquidity behaviour
- No liquidity callbacks.
- Fee behaviour
- The pool's static fee is used at the pool level; the hook exposes a feeConfig view and a MAX_LP_FEE constant but the decoded bytecode does not show a clear dynamic fee being returned from beforeSwap. Value taken by the hook is handled through afterSwap return deltas.
- Owner & admin controls
- The owner can transfer or renounce ownership, change the treasury address, and set the reward split parameters through setSplits and setTreasury. The owner can change the split percentages affecting how hook-collected funds are distributed.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeSwap, afterSwap, afterSwapReturnDelta
beforeInitialize registers currencies and marks pools as tracked. beforeSwap is present as a view-dispatched selector and its use is not fully determined. afterSwap updates accounting and takes a share via the return delta. afterSwapReturnDelta lets the hook take currency out of swap settlement.
Security & trust assessment
Risk level: high, estimated (decoded bytecode, low confidence).
Who controls it: A single owner key can change the treasury address and reward split percentages, redirecting hook-collected funds to a destination of its choosing.
Risk to user funds: The hook holds balances in ERC6909 claims and takes a portion of swaps via return deltas, so swap outputs and accumulated pots are exposed to the owner-controlled split and treasury settings.
Security findings
- [medium] Hook takes swap output via return deltas: afterSwapReturnDelta is enabled and afterSwap moves currency, so the hook can withhold part of each swap's output from traders.
- [high] Owner controls fund split and treasury destination: setSplits and setTreasury let the owner redirect hook-collected value; the owner can set the split and treasury address without a visible timelock in the bytecode.
- [info] Ownable with renounce and transfer: Ownership can be transferred or renounced, so administration of the split and treasury parameters depends on the owner key.
- [medium] Self-unlock and currency movement: The hook calls unlock and handles unlockCallback, moving currency through take and settle; correctness of accounting depends on the callback logic which cannot be verified without source.
Contract details
- Verified source
- No
- Bytecode size
- 12,301 bytes
- Upgradeable proxy
- No
- Detected patterns
- erc20, erc6909-claims, moves-currency, ownable, return-delta, rewards, self-unlock
Pools using Rewards hook
- ETH / WOC (Dynamic fee) — 24h volume $1.24K, TVL $0, 17 swaps today