Token hook on Ethereum
Uniswap v4 Hook Contract 0x57991106cb7aa27e2771beda0d6522f68524a888 on Ethereum · Token
- Volume (24h)
- $0
- Value locked (TVL)
- $0
- All-time volume
- $0
- Pools using this hook
- 1
- Swaps (24h)
- 115 (73 traders)
- Total swaps
- 100,705
What it does
Lets traders swap ETH for WETH and back at a strict 1:1 rate through a Uniswap v4 pool, with no fees and no liquidity providers.
How it works step by step
- Validates in beforeInitialize that the pool pairs WETH with native ETH and has a zero fee.
- Blocks every liquidity addition in beforeAddLiquidity, so the pool holds no LP liquidity.
- On swaps in the wrap direction, takes ETH from the PoolManager and deposits it into WETH, then settles the minted WETH back to the PoolManager.
- On swaps in the unwrap direction, takes WETH into the hook, calls withdraw to receive ETH, and settles the ETH to the PoolManager.
- Returns a custom BeforeSwapDelta so the swap completes entirely through the wrap or unwrap without using pool liquidity.
- Swap behaviour
- On each swap the hook either wraps ETH into WETH by depositing into the WETH contract, or unwraps WETH to ETH by withdrawing from it, depending on swap direction; exact-input and exact-output swaps are both supported at a 1:1 ratio.
- Liquidity behaviour
- beforeAddLiquidity always reverts with LiquidityNotAllowed, so no liquidity can be added. Remove liquidity has no hook callback.
- Fee behaviour
- Pool fee must be 0 (InvalidPoolFee otherwise); the hook returns lpFeeOverride 0 and charges no fee on wrap/unwrap.
- Owner & admin controls
- No admin controls found. The hook has no owner, pause, upgrade or parameter-setting functions; wrapper and underlying currencies and the WETH address are fixed as immutables at construction.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeAddLiquidity, beforeSwap, beforeSwapReturnDelta
beforeInitialize validates the pair is WETH/ETH with zero fee; beforeAddLiquidity blocks all liquidity additions; beforeSwap performs the 1:1 ETH-to-WETH wrap or WETH-to-ETH unwrap and returns a custom delta; beforeSwapReturnDelta lets the hook override the swap's accounting.
Security & trust assessment
Risk level: low (verified source, high confidence).
Who controls it: No privileged role exists, so no key can alter behaviour, pause swaps or drain funds through the hook.
Risk to user funds: Users swap through the hook at a strict 1:1 ratio between ETH and WETH with no fee and no admin intervention. The hook only moves funds within a single swap call via the PoolManager, and the WETH contract is an immutable, externally fixed address.
Security findings
- [info] Hook supplies custom swap accounting: beforeSwapReturnDelta is enabled, so the hook fully sets the swap's input and output amounts. Swaps are only ever 1:1 wrap or unwrap, with exact-input and exact-output paths both implemented.
- [info] Transient custody of ETH and WETH: The hook holds ETH and WETH transiently during a wrap or unwrap and settles them with the PoolManager within the same call, so it is not intended to hold user balances.
- [low] Unrestricted ETH receive with no withdrawal path: The receive() function accepts any ETH without restriction. Stray ETH sent directly to the hook is not recoverable by any function.
Contract details
- Verified source
- No
- Bytecode size
- 6,257 bytes
- Upgradeable proxy
- No
- Detected patterns
- return-delta
Pools using Token hook
- ETH / WETH (0.00% fee) — 24h volume $0, TVL $0, 115 swaps today