FuyuHook on Ethereum

Uniswap v4 Hook Contract 0xbd283d8a09d254c5d54bc43e7c6b1611f76ba0cc on Ethereum · Custom pricing · Verified contract

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

What it does

Every ETH trade in the FUYU pool, buy or sell, pays a tax that starts at 85% when trading opens and falls linearly to 1% over 22 minutes, so early traders pay far more than later ones, and the tax is collected in ETH only.

How it works step by step

  • Creates the ETH/FUYU pool only through the deployer's openPool(), adding FUYU-only single-sided liquidity as a v4 position NFT owned by the deployer; any other pool creation attempt reverts in beforeInitialize.
  • Keeps trading frozen until the deployer calls thaw(), after which beforeSwap and afterSwap are active and gate swaps behind a thawedAt check.
  • Applies a time-decaying tax of 85% on buys and sells at thaw, falling linearly to 1% over 22 minutes and staying at 1% thereafter; the tax rate is fixed in code.
  • Takes the tax in ETH only, by returning a before-swap or after-swap delta and minting the equivalent ETH as ERC-6909 claims to the hook inside the PoolManager.
  • Lets only the deployer withdraw accumulated ETH tax via unlockCallback, which burns the claims and takes ETH to the chosen recipient.
  • Charges a 0.3% LP fee on top of the hook tax through the pool's static fee setting.
Swap behaviour
Before every swap the hook reverts if trading is not yet thawed. For buys (ETH to FUYU) with exact-in amounts, and sells with exact-out amounts, the tax is taken in beforeSwap as a share of the ETH amount. For exact-out buys and exact-in sells, the tax is taken in afterSwap, either added on top of the ETH paid or taken from the ETH received. Every swap pays the current tax rate (85% decaying to 1%), so early trades in both directions pay far more than later ones, with buys and sells treated symmetrically.
Liquidity behaviour
No liquidity callbacks. The launch liquidity is added once by openPool() through the PositionManager and is not locked; the position owner can collect fees or remove liquidity through the normal v4 flow, which the hook does not intercept.
Fee behaviour
The pool uses a static 0.3% LP fee, paid to the liquidity position. On top of that the hook takes a time-decaying ETH tax of 85% at thaw, linearly falling to 1% over 22 minutes and then fixed at 1%. The tax is never paid in FUYU and goes to the hook's ERC-6909 treasury, withdrawable only by the deployer.
Owner & admin controls
The deployer address (immutable) can call openPool once to create the pool and add liquidity, call thaw once to start trading, and call withdraw to send accumulated tax ETH to any address. The deployer cannot change the tax rate, decay duration, LP fee, pause trading, blacklist addresses, or upgrade the contract; the contract is not a proxy.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta

beforeInitialize reverts all pool creation except the hook's own openPool path. beforeSwap enforces the thaw gate and computes and collects the tax on eligible swaps by returning a specified-side delta. afterSwap collects the tax on the other swap configurations by returning an unspecified-side delta. beforeSwapReturnDelta and afterSwapReturnDelta permit those deltas to be applied to the trader's settlement.

Security & trust assessment

Risk level: medium (verified source, high confidence).

Who controls it: A single deployer key can create the pool at a chosen starting tick, open trading once, and withdraw all collected ETH tax. It also owns the launch LP position NFT and can remove that liquidity at any time. It cannot change the tax schedule, pause swaps, or upgrade the hook.

Risk to user funds: The hook holds no user principal directly; it holds only ETH tax claims in the PoolManager. Swaps are never blocked by ETH transfers out since withdrawals are done separately. Users' swap funds flow through the pool and PoolManager, and the hook can take up to 85% of a trade's ETH value during the early decay window; the deployer's LP position can remove liquidity from the pool.

Security findings

  • [info] Deployer can withdraw all accumulated tax: withdraw() sends the full pendingTax() balance of ERC-6909 ETH claims held by the hook to any address, callable only by the immutable deployer; this is the intended treasury design but concentrates control of collected fees in one key.
  • [medium] Swaps depend on hook-side delta accounting: Trades are settled through beforeSwap and afterSwap return deltas that mint ETH claims to the hook; a mistake in the tax arithmetic or the sign/branch logic would affect every swap, though the code guards against sign-wrapping and int128 overflow in the visible paths.
  • [info] Pool creation and trading gate are one-shot: openPool and thaw can each run only once (openedAt and thawedAt checks), so the deployer cannot re-open liquidity or re-thaw after launch.
  • [low] Position NFT is not locked: The launch liquidity position is minted to the deployer and can be removed at any time, which lets the deployer pull liquidity from the pool.

Contract details

Verified source
Yes (FuyuHook)
Compiler
solc 0.8.30+commit.73712a01
Bytecode size
11,340 bytes
Upgradeable proxy
No
Detected patterns
erc6909-claims, moves-currency, return-delta, self-unlock, tax

Pools using FuyuHook