V4AlphaHook on Ethereum
Uniswap v4 Hook Contract 0xb0bbf26a84587e91f9c0ffa5622940c3324e2880 on Ethereum · Launchpad · Verified contract
- Volume (24h)
- $0
- Value locked (TVL)
- $0
- All-time volume
- $35.07M
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 41,965
What it does
A launchpad-style hook that keeps a Uniswap v4 pool closed to swaps and non-owner liquidity until an owner-set start timestamp, then opens it to normal trading.
How it works step by step
- Owner initializes a pool through initializePool, storing a start timestamp and initializing the pool in PoolManager at a chosen sqrt price.
- beforeInitialize only allows initialization if the pool was enabled and the transaction origin is the hook owner.
- beforeAddLiquidity blocks liquidity additions before the start time unless the sender is a registered pool owner or the trusted PositionManager's msgSender is one.
- beforeSwap blocks all swaps before the start time and passes through afterwards with no fee or delta changes.
- Owner manages a per-pool allowlist of pool owners and can adjust the start time until the pool has started.
- Owner can rescue ETH, ERC20 and ERC721 assets held by the hook.
- Swap behaviour
- beforeSwap reverts with PoolNotStarted until the pool's start timestamp has passed; after that it returns a zero delta and zero fee override, so swaps execute normally.
- Liquidity behaviour
- beforeAddLiquidity reverts with PoolNotStarted unless the pool has started or the sender is a pool owner (directly or via the trusted PositionManager's msgSender). No remove-liquidity callbacks are enabled.
- Fee behaviour
- Uses the pool's static fee. beforeSwap returns a zero delta and zero override fee.
- Owner & admin controls
- Owner (Ownable2Step, must be an EOA) can initialize pools via initializePool, set or change pool start times via setPoolStartTime, add or remove pool owners (who may add liquidity before the pool starts), change the trusted positionManager via setPositionManager, transfer or renounce ownership, and call emergencyWithdraw, emergencyWithdrawERC20Unsafe and emergencyWithdrawERC721 to move any ETH, ERC20 or ERC721 held by the hook to the owner.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeAddLiquidity, beforeSwap
beforeInitialize: requires the pool to be enabled by the owner and the transaction origin to be the hook owner. beforeAddLiquidity: gates liquidity provision until the pool start time, with an exception for pool owners. beforeSwap: blocks all swaps until the pool start timestamp has passed.
Security & trust assessment
Risk level: medium (verified source, high confidence).
Who controls it: The owner EOA controls which pools exist and when they open, can grant or revoke pool-owner privileges, can repoint the trusted PositionManager, and can drain any tokens or ETH held by the hook. A compromised owner key could therefore withdraw hook balances or redirect authorization.
Risk to user funds: The hook does not take fees or return deltas, so normal swaps and LP flows pass through unchanged once a pool is started. However, it can hold ETH or tokens (it has a receive function and emergency withdraw paths), and the owner can withdraw any balance it holds. Users can be blocked from swapping or adding liquidity until the owner-set start time, and pools cannot be traded if the owner never sets or leaves the start time in the future.
Security findings
- [medium] Owner can withdraw all hook-held assets: emergencyWithdraw, emergencyWithdrawERC20Unsafe and emergencyWithdrawERC721 let the owner transfer any asset the hook holds to the owner address. The ERC20 variant ignores the transfer return value.
- [medium] Owner controls pool start timing: setPoolStartTime lets the owner change the start timestamp of any initialized pool until it has started, so trading and liquidity access can be delayed or retimed arbitrarily.
- [medium] Authorization depends on tx.origin and owner-set PositionManager: _beforeInitialize relies on tx.origin == owner(), and setPositionManager trusts whatever contract the owner sets for msgSender() in _isAuthorizedPoolOwner, so authorization depends on owner-controlled configuration rather than on-chain roles alone.
- [info] Non-upgradeable with EOA owner requirement: The hook is not upgradeable (no proxy pattern in the decoded interface) and enforces that the owner is an EOA, which avoids contract-owner tx.origin issues but cannot be changed without redeploying.
- [info] No swap-time token extraction: The hook returns a zero BeforeSwapDelta and does not use return-delta permissions, so it does not take tokens from swaps or LP positions by itself.
Contract details
- Verified source
- Yes (V4AlphaHook)
- Compiler
- solc 0.8.26+commit.8a97fa7a
- Bytecode size
- 10,966 bytes
- Upgradeable proxy
- No
- Detected patterns
- ownable
Pools using V4AlphaHook
- USDT / H (0.01% fee) — 24h volume $0, TVL $0, 0 swaps today