Auction hook on Ethereum
Uniswap v4 Hook Contract 0xa79d4623ff6b9fcb9bd45c8ea7c476e6cea0a8cc on Ethereum · Auction
- Volume (24h)
- $199
- Value locked (TVL)
- $0
- All-time volume
- $199
- Pools using this hook
- 1
- Swaps (24h)
- 9 (7 traders)
- Total swaps
- 9
What it does
This hook runs an auction-style mechanism that takes a share of swap flows through return deltas and routes fees into pot, owner and LP accounting, with the exact split and trade-direction effects not confirmable without source.
How it works step by step
- Opens a pool-bound auction/launch mechanic gated by beforeInitialize, with a pool key and tick range recorded at open time
- Uses beforeSwap and afterSwap with return deltas, so the hook can take a share of swap amounts and adjust what the swapper receives
- Accrues fees into internal buckets (feeTotal, pot, ownerOwed, paidTotal) and tracks per-address credit and claimable balances
- Pages and ticks through price levels (pagePrice, rateOf, MAX_PAGES, PRICE_FLOOR) and can reboot or reap state over time
- Uses an unlockCallback that re-enters the pool manager to settle deltas, which is a self-unlock pattern
- Swap behaviour
- Swaps run through beforeSwap and afterSwap, which can return deltas to the pool manager; the hook can take a portion of swap amounts and may change the output a trader receives. The exact split between trade directions could not be determined from decoded bytecode alone.
- Liquidity behaviour
- beforeAddLiquidity is gated and afterAddLiquidity is present in the dispatch table; beforeRemoveLiquidity and afterRemoveLiquidity are also exposed. Adding liquidity appears to update internal liquidity-related storage, but the precise rules cannot be confirmed without source.
- Fee behaviour
- Fees are routed into internal accounting buckets (feeTotal, pot, ownerOwed) and split among the pot, owner and LP shares via POT_FEE, OWNER_FEE and LP_FEE getters; the fee is taken through return deltas rather than the pool's static fee. Exact percentages cannot be confirmed from bytecode.
- Owner & admin controls
- An OWNER() getter and a payOwner() function exist, so an owner address can receive owner-share funds. reboot() and reap(address) suggest owner or state-reset capabilities. No explicit pause function was identified, but the decoded functions do not fully reveal the access checks.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeAddLiquidity, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta
beforeInitialize: records the pool id and opens the hook state for the pool. beforeAddLiquidity: gates liquidity additions. beforeSwap: may return a delta to take a fee or adjust swap amounts. afterSwap: updates accounting and may return a delta. beforeSwapReturnDelta and afterSwapReturnDelta: allow the hook to move currency amounts on swaps.
Security & trust assessment
Risk level: high, estimated (decoded bytecode, low confidence).
Who controls it: The owner can receive owner-share funds through payOwner and may reboot or reap hook state, so a privileged key has meaningful control over accrued balances.
Risk to user funds: The hook holds accrued pot, fee and credit balances and takes currency through return deltas during swaps, so user and pool funds pass through hook-controlled accounting.
Security findings
- [high] Return deltas can alter swap amounts: beforeSwapReturnDelta and afterSwapReturnDelta are enabled, so the hook can take or reallocate currency during swaps, directly affecting trader outputs.
- [medium] Owner-controlled reboot and reap: The owner-facing reboot() and reap(address) functions can reset or sweep hook state, which could affect accrued balances if access control is weak.
- [medium] Self-unlock callback: unlockCallback is reachable and the hook re-enters the pool manager to settle deltas, so the callback's authorization is critical; an error there could let arbitrary callers move funds.
- [info] No source verification: Behaviour is inferred from decoded selectors and storage only; access modifiers and math could not be read directly.
Contract details
- Verified source
- No
- Bytecode size
- 13,634 bytes
- Upgradeable proxy
- No
- Detected patterns
- return-delta, self-unlock
Pools using Auction hook
- ETH / OOM (1.00% fee) — 24h volume $199, TVL $0, 9 swaps today