LongHook on Arc

Uniswap v4 Hook Contract 0xfb6369c30573f9af1b88314c732fca944a34e0cc on Arc · Fee sharing · Verified contract

Volume (24h)
$0
Value locked (TVL)
$428
All-time volume
$19.30K
Pools using this hook
136
Swaps (24h)
1 (1 traders)
Total swaps
3,552

What it does

Charges a fixed base-token fee (up to 10%) on every swap of a Long launch pool and splits the accrued fee among creator, holders, protocol, burn and flywheel buckets.

How it works step by step

  • Charges a per-pool fee in basis points, capped at 10%, taken only in the pool's base token regardless of swap direction.
  • Takes the fee as a PoolManager mint claim in beforeSwap or afterSwap and accrues it per launch token.
  • Splits accrued fees into creator, holders, protocol, burn and flywheel buckets when banked at withdrawal time.
  • Lets anyone withdraw creator and protocol shares, and lets owner-approved operators withdraw holders, flywheel and burn shares.
  • Only allows registration from owner-approved factories and only for pools whose base token is one of the pool's currencies.
Swap behaviour
On swaps where the specified currency is the base token, beforeSwap takes the fee from the specified amount. On swaps where the unspecified currency is the base token, afterSwap takes the fee from the unspecified amount and requires full fills. Swaps that do not involve the base token pass through unchanged.
Liquidity behaviour
No liquidity callbacks.
Fee behaviour
A flat fee in basis points (capped at MAX_FEE_BPS = 1000, i.e. 10%) is set per pool at registration and charged on the base token only. The fee is taken in beforeSwap when the specified currency is the base token, and in afterSwap when the unspecified currency is the base token. The fee is minted as a PoolManager claim and accrued per launch token, then split into five buckets (creator, holders, protocol, burn, flywheel) at withdrawal time, with rounding dust going to flywheel.
Owner & admin controls
Owner (set via setOwner) can set protocolRecipient, allow or disallow factories that may register pools, assign holders/flywheel/burn operators, redirect any launch's creator share via setCreatorRecipient, and change the split of any live pool via setPoolSplit. The per-pool fee is fixed at registration and cannot be changed by the owner. No pause function, no upgrade proxy, and no emergency withdrawal path was found.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta

beforeInitialize restricts pool initialization to allowed factories and registered pool keys. beforeSwap and afterSwap (both with return-delta permissions) charge the base-token fee by adjusting the specified or unspecified currency delta. The beforeSwapReturnDelta and afterSwapReturnDelta flags let the hook take the fee as a delta, which is the mechanism that moves value out of the trade.

Security & trust assessment

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

Who controls it: The owner can point the creator share of any launch at an arbitrary address and can change the split of any live pool, including setting the flywheel or burn shares to 100% of future fees, redirecting fees away from creators and holders. Operators for holders, flywheel and burn buckets can drain their banked balances to any address. Owner also controls which factories can register pools.

Risk to user funds: The hook holds base-token fees as PoolManager claims and does not hold trader principal. Fees are withdrawable by anyone for creator and protocol buckets, and by owner-approved operators for the other three. Owner-driven split or recipient changes can redirect future fee flows, but do not touch funds already banked under prior terms. Traders' swap principal flows through the pool manager, not the hook.

Security findings

  • [medium] Owner can change fee split on live pools: setPoolSplit lets the owner change a live pool's split at any time (forward-only, after banking accrued fees). The owner could shift all future fees to flywheel or protocol, changing what creators and holders are owed.
  • [medium] Owner can redirect creator share: setCreatorRecipient can redirect any launch's creator share to any address, so the creator's withdrawal destination is controlled by the owner rather than the creator.
  • [medium] Operator withdrawal authority over three buckets: Holders, flywheel and burn withdrawals are gated by operator mappings set by the owner. A compromised or malicious operator can withdraw banked fees for those buckets to any address.
  • [low] Fee taken via return deltas with full-fill requirement: The hook takes fees via return deltas and PoolManager mint claims in beforeSwap and afterSwap. afterSwap reverts with IncompleteFill for partial fills on the fee path, so a swap whose realised amount does not match the expected amount plus fee will fail.
  • [info] Fee cap and split validation enforced: The fee cap is 10% and the split must sum to exactly 10000 bps, validated at registration and on split change. Rounding dust is credited to flywheel.

Contract details

Verified source
Yes (LongHook)
Compiler
solc 0.8.26+commit.8a97fa7a
Bytecode size
10,096 bytes
Upgradeable proxy
No
Detected patterns
moves-currency, return-delta, self-unlock

Pools using LongHook