Launchpad hook on Ethereum

Uniswap v4 Hook Contract 0x61cde95a535e441f5ae97a995d63ad28c5f660cc on Ethereum · Launchpad

Volume (24h)
$242
Value locked (TVL)
$0
All-time volume
$242
Pools using this hook
1
Swaps (24h)
4 (1 traders)
Total swaps
4

What it does

A Uniswap v4 hook that appears to skim a platform share of swap fees for a token launchpad, tracking pending fees per address that can be claimed later.

How it works step by step

  • Registers pools and tokens in beforeInitialize and afterInitialize, keeping a pool key mapping and a token list
  • Takes a platform share of swap value through beforeSwapReturnDelta and afterSwapReturnDelta
  • Accumulates pending fees per address and in total (pendingFees, totalPending)
  • Lets recipients withdraw accrued fees through claim
  • Allows the fee recipient for a pool to be set through setFeeRecipient
  • Uses unlock and unlockCallback to settle and take currency from the pool manager
Swap behaviour
beforeSwap and afterSwap run on every swap; the hook uses return deltas to take its share of the swap amount and records pending fees for the platform and recipients.
Liquidity behaviour
Before and after add/remove liquidity callbacks are implemented and the hook appears to track liquidity via a total supply constant (TOTAL_SUPPLY) and a token registry; it may mint or hold position-related accounting, but the exact behaviour is not confirmed.
Fee behaviour
The hook keeps a platform share (platformShareBps) of fees, capped by MAX_FEE_BPS, and tracks pending fees per address (pendingFees, totalPending, claim). Exact fee calculation could not be confirmed from bytecode alone.
Owner & admin controls
setFeeRecipient(address,address) is a state-changing function with no visible owner check in the decoded selectors; the hook stores a per-pool mapping (slot 0) that it writes, so whoever can call it may redirect fee recipients. No owner, pause or upgrade functions were decoded, though platformWallet, platformShareBps, MAX_FEE_BPS and metadataAdmin/setMetadataAdmin suggest a privileged platform role that controls fee share and recipients.

Enabled Uniswap v4 callbacks

beforeInitialize, beforeSwap, afterSwap, beforeSwapReturnDelta, afterSwapReturnDelta

beforeInitialize registers pools and tokens; beforeSwap and afterSwap read the pool key mapping and update per-address pending fee accounting; beforeSwapReturnDelta and afterSwapReturnDelta let the hook take a share of swap amounts as a delta, which is how it extracts its fee.

Security & trust assessment

Risk level: medium (decoded bytecode, low confidence).

Who controls it: A privileged key can change the fee recipient for a pool through setFeeRecipient and may control platform wallet and share parameters, which would change how swap fees are split between users and the platform.

Risk to user funds: The hook can take a portion of swap amounts through return deltas and temporarily holds tokens during unlock callbacks, so it can divert part of traded value; funds held in claimable pending-fee balances are subject to the claim logic.

Security findings

  • [medium] Return deltas take a share of swap value: The hook uses beforeSwapReturnDelta and afterSwapReturnDelta and moves currency via take/settle, so it removes a portion of swap value from the pool flow.
  • [high] Fee recipient change may lack access control: setFeeRecipient is externally callable and writes the per-pool recipient mapping; no access check was decoded in the visible selectors.
  • [medium] Self-unlock and token movement inside callbacks: The hook self-unlocks the pool manager (unlock/unlockCallback) and transfers ERC-20 tokens, which means it holds tokens transiently during callbacks.
  • [info] Platform share is a configurable parameter: Platform wallet and share in basis points are configurable parameters, so the split of fees can be changed by whoever controls the metadataAdmin or platform role.

Contract details

Verified source
No
Bytecode size
18,752 bytes
Upgradeable proxy
No
Detected patterns
erc20, moves-currency, return-delta, self-unlock

Pools using Launchpad hook