LaunchGuardHook on Ethereum
Uniswap v4 Hook Contract 0xcb69d5abe0589af4c57b0dcca292980d5e52c0c0 on Ethereum · Launchpad · Verified contract
- Volume (24h)
- $76.52K
- Value locked (TVL)
- $197.61K
- All-time volume
- $40.94M
- Pools using this hook
- 763
- Swaps (24h)
- 364 (210 traders)
- Total swaps
- 143,588
What it does
A swap guard for fresh token launches: during the launch block only the factory's opening buy may swap, and in the following window each buyer is capped on how much of the token they can take from the pool and in total.
How it works step by step
- beforeSwap reverts any swap in the token's launch block unless the sender is the token's factory, which is the creator's opening buy.
- afterSwap reads the guard state from the pool's currency1 token (guardActive, launchBlock, currentBuyCap, MAX_HOLD) and skips the check if the pool does not hold a token that reports a factory.
- Buys (currency1 leaving the pool) larger than currentBuyCap revert the whole swap after the amount is known.
- A running per-pool, per-tx.origin total of bought amounts is kept in boughtInWindow and reverts when it exceeds MAX_HOLD.
- Sells (zeroForOne swaps) and all liquidity, donate and initialize callbacks are not capped or touched.
- Swap behaviour
- beforeSwap blocks non-factory swaps in the launch block. afterSwap, when guard is active and the swap is a buy after the launch block, reverts if the buy exceeds the current buy cap or pushes the buyer's cumulative amount over the hold cap; otherwise it accepts the swap with no delta change.
- Liquidity behaviour
- No liquidity callbacks.
- Fee behaviour
- Uses the pool's static fee. The hook returns zero delta and no fee override.
- Owner & admin controls
- No owner, pause, upgrade or parameter setter is present in the ABI or source. Limits come from the token contract's own state (currentBuyCap, MAX_HOLD, guardActive, launchBlock) which the hook reads but does not control.
Enabled Uniswap v4 callbacks
beforeSwap, afterSwap
beforeSwap is used to refuse non-creator swaps in the launch block before any output is settled. afterSwap is used to enforce the per-buy cap and the cumulative hold cap on the measured output amount.
Security & trust assessment
Risk level: medium (verified source, medium confidence).
Who controls it: The hook itself has no privileged role. Whoever controls the launched token's factory and token state (guardActive, currentBuyCap, MAX_HOLD) effectively controls how this guard behaves, and those values are not visible in this hook's source.
Risk to user funds: The hook does not custody or move tokens and returns zero deltas. It can revert swaps, which blocks buys in the launch block for non-factory senders and blocks buys over the caps; it cannot take funds.
Security findings
- [medium] Caps depend on the token contract: The guard values are read from the currency1 token via factory(), currentBuyCap(), guardActive(), MAX_HOLD() and launchBlock(). A token that returns misleading values or is itself upgradeable can change or disable the guard without any change to this hook.
- [low] Hold cap keyed on tx.origin: boughtInWindow uses tx.origin, so a buyer can split purchases across several wallets to get more than one hold cap, and contracts that relay for users share a bucket. The comment acknowledges the key choice but it does not prevent multi-wallet circumvention.
- [low] Hook trusts currency1 as the token: _guarded treats whatever address sits in currency1 as the launched token. A pool with a non-launch token that happens to return a factory() address is subject to these rules, and a pool that does not is skipped silently, so the guard only applies to pools that follow the factory's sorting convention.
- [info] Bucket never cleared: boughtInWindow is never reset, per the source comment. It is keyed per pool so it only matters for that pool, but it grows without bound and is not enforced by time after the window closes; afterSwap still applies MAX_HOLD to later buys if guardActive stays true.
- [info] Unused callbacks present: Only beforeSwap and afterSwap are enabled by the address, so the other IHooks functions in the ABI are inert stubs that the PoolManager does not call.
Contract details
- Verified source
- Yes (LaunchGuardHook)
- Compiler
- solc 0.8.26+commit.8a97fa7a
- Bytecode size
- 2,776 bytes
- Upgradeable proxy
- No
Pools using LaunchGuardHook
- ETH / SENDOVER (1.00% fee) — 24h volume $49.59K, TVL $48.16K, 199 swaps today
- ONDO / CONDO (1.00% fee) — 24h volume $16.05K, TVL $34.39K, 71 swaps today
- ETH / SNOWMOON (1.00% fee) — 24h volume $5.09K, TVL $13.12K, 18 swaps today
- ETH / ZC (1.00% fee) — 24h volume $3.59K, TVL $10.48K, 19 swaps today
- NVDAon / AP (1.00% fee) — 24h volume $690, TVL $2.73K, 2 swaps today
- NVDAon / AP (1.00% fee) — 24h volume $338, TVL $1.04K, 1 swaps today
- PEPE / KEK (1.00% fee) — 24h volume $284, TVL $4.29K, 2 swaps today
- ETH / SENDCAT (1.00% fee) — 24h volume $234, TVL $2.36K, 2 swaps today
- NVDAon / 爱 (1.00% fee) — 24h volume $217, TVL $3.01K, 1 swaps today
- UNI / PAWSINU (1.00% fee) — 24h volume $183, TVL $2.30K, 1 swaps today
- SEND / SCAT (1.00% fee) — 24h volume $122, TVL $0, 1 swaps today
- ETH / GLADIAS (1.00% fee) — 24h volume $109, TVL $1.50K, 2 swaps today
- ETH / CWC (1.00% fee) — 24h volume $12, TVL $71, 1 swaps today
- PEPE / FEELSGOOD (1.00% fee) — 24h volume $12, TVL $429, 1 swaps today
- TSLAon / FTR (1.00% fee) — 24h volume $0, TVL $0, 2 swaps today
- NVDAon / BOAR (1.00% fee) — 24h volume $0, TVL $821, 0 swaps today
- ETH / GOVCOIN (1.00% fee) — 24h volume $0, TVL $1.56K, 0 swaps today
- ETH / ZC (1.00% fee) — 24h volume $0, TVL $1.57K, 0 swaps today
- ETH / BOAR (1.00% fee) — 24h volume $0, TVL $1.07K, 0 swaps today
- NVDAon / DBINU (1.00% fee) — 24h volume $0, TVL $596, 0 swaps today