Launchpad hook on Ethereum
Uniswap v4 Hook Contract 0xcbc1fe95e9283e1e6cd6b560f419d15a3c6d20cc on Ethereum · Launchpad
- Volume (24h)
- $582
- Value locked (TVL)
- $0
- All-time volume
- $582
- Pools using this hook
- 1
- Swaps (24h)
- 5 (2 traders)
- Total swaps
- 5
What it does
This hook runs a launchpad-style pool that checks the opening price at initialization and takes a fee on swaps through return deltas, but the direction and size of the fee for buyers versus sellers could not be determined from the bytecode.
How it works step by step
- Exposes a registry of builders and badges via register(address,uint256), badgeOf(address) and builder(address), with builder addresses stored in mappings keyed by address.
- Pairs a token with an opening price and tick (OPEN_SQRT_PRICE, OPEN_TICK, SPACING) and checks the initialization price in beforeInitialize, reverting with WrongPrice when it does not match.
- beforeSwap and afterSwap take a bytes payload and can alter the swap through return deltas, so the hook can charge or redirect value during a swap.
- Accrues a fee (FEE_BPS, LP_FEE) that is tracked in storage (feesCollected, pending) and swept out with collect() via unlockCallback and take.
- Uses CREATE3 through CREATEX with a salt, reverting on BadSalt or NotDeployer, to deploy a companion contract at a deterministic address (create3Address).
- Swap behaviour
- beforeSwap and afterSwap run on every swap and can apply a return delta, so the hook can take a portion of the swap amount; the exact condition under which buys or sells pay more could not be determined from the bytecode.
- Liquidity behaviour
- No liquidity callbacks.
- Fee behaviour
- Accrues a fee in basis points (FEE_BPS) that is recorded in pending and feesCollected and withdrawn through collect(); the LP_FEE view suggests a fee also flows to the pool, but the split could not be determined from decoded bytecode.
- Owner & admin controls
- An OWNER view exists and register/collect call paths appear to be restricted, but the exact access checks could not be confirmed without source; any owner-only setters for fee parameters are not visible in the dispatch table.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta
beforeInitialize checks the opening price against the configured open sqrt price and tick; beforeSwap and afterSwap are used with return deltas to take a fee or adjust the swap amount; beforeSwapReturnDelta and afterSwapReturnDelta allow the hook to alter the amounts settled for the swapper.
Security & trust assessment
Risk level: medium, estimated (decoded bytecode, low confidence).
Who controls it: A privileged owner or deployer key likely controls the register list and fee collection, and could drain accrued fees if collect is not properly gated.
Risk to user funds: The hook takes and settles currency through return deltas and the pool manager, so it can hold and move part of each swap's funds; it does not appear to block swaps outright.
Security findings
- [medium] Return-delta fee capture: beforeSwap and afterSwap are paired with beforeSwapReturnDelta and afterSwapReturnDelta, so the hook settles currency on each swap and can take a cut of user funds.
- [medium] Self-unlock and currency movement: The hook calls unlock and take on the pool manager (unlockCallback, collect), so it moves currency itself and the withdrawal path depends on its access checks.
- [info] Unverified access control: No source is available, so it cannot be confirmed that collect and register are restricted to the owner or deployer.
Contract details
- Verified source
- No
- Bytecode size
- 5,579 bytes
- Upgradeable proxy
- No
- Detected patterns
- moves-currency, return-delta, self-unlock
Pools using Launchpad hook
- ETH / F0 (0.30% fee) — 24h volume $582, TVL $0, 5 swaps today