Custom pricing hook on BNB Chain

Uniswap v4 Hook Contract 0x83863f772f93e2a209dab0af924ca3d6764a40c4 on BNB Chain · Custom pricing

Volume (24h)
$0
Value locked (TVL)
$0.01
All-time volume
$1.20M
Pools using this hook
3
Swaps (24h)
0 (0 traders)
Total swaps
25,193

What it does

A Uniswap v4 hook with owner-controlled quote signing and whitelisting that gates or adjusts swaps and can take a return delta from them, with an egRecipient and token claim mechanism.

How it works step by step

  • Gates swaps in beforeSwap against a whitelist mapping and a stored quote signer address.
  • Uses afterSwap with afterSwapReturnDelta enabled to take or return tokens from each swap.
  • Maintains a claimable mapping and claimEgTokens function to distribute accrued tokens to addresses.
  • Sends accrued amounts to an egRecipient address that the owner can update.
  • Lets the owner rescue ERC20, ERC721 and ERC1155 tokens the hook holds.
  • Liquidity and donate callbacks exist in code but are not enabled by the hook's permissions.
Swap behaviour
beforeSwap checks whitelisted status and a stored quote signer (likely verifying signed quote data), and afterSwap applies post-swap accounting with a possible return delta.
Liquidity behaviour
Liquidity add and remove callbacks (beforeAddLiquidity, afterAddLiquidity, beforeRemoveLiquidity, afterRemoveLiquidity) are present in the dispatch table but the hook does not declare these permissions, so they are not invoked by the PoolManager; no liquidity logic is active.
Fee behaviour
No fee is set by name in the decoded functions; the hook's beforeSwap and afterSwap logic appears to rely on signed quotes from a stored quote signer and may take a return delta from swaps, but the exact fee or delta formula cannot be determined from the decoded bytecode alone.
Owner & admin controls
Owner (Ownable: transferOwnership, renounceOwnership) can set the quote signer (updateQuoteSigner) and the egRecipient (updateEgRecipient), manage whitelisted and claimable address mappings (updateWhitelisted, updateClaimable), and rescue ERC20, ERC721 and ERC1155 tokens held by the hook to an arbitrary address.

Enabled Uniswap v4 callbacks

beforeSwap, afterSwap, afterSwapReturnDelta

beforeSwap: gates or prices swaps, likely checking a whitelist and a signed quote from the quote signer; afterSwap: post-swap accounting and possibly taking a return delta (afterSwapReturnDelta enabled), which lets the hook take or give tokens from the swap.

Security & trust assessment

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

Who controls it: The owner can replace the quote signer, which controls which quotes are honored, and can whitelist or un-whitelist addresses, so a compromised owner or signer key could steer or block swaps for users. The owner can also rescue any tokens the hook holds, including accumulated swap deltas.

Risk to user funds: The hook can hold and move tokens through afterSwapReturnDelta and can have its balances rescued by the owner; users' swap funds pass through the hook's accounting, so a privileged key can affect or withdraw amounts the hook holds.

Security findings

  • [medium] Return delta permission lets hook take swap funds: afterSwapReturnDelta is enabled, so the hook can take or return token amounts from each swap and settle them itself rather than the pool.
  • [medium] Owner can rescue hook-held tokens: rescueERC20s, rescueERC721s and rescueERC1155s let the owner transfer any token balance the hook holds to an address of their choice.
  • [medium] Owner controls swap eligibility and quote signer: The owner can change quoteSigner and the whitelist mappings, which determine who may swap and which quotes are accepted.
  • [info] Ownable, non-upgradeable: Contract is Ownable with transferOwnership and renounceOwnership; no proxy or upgrade selector was found, so the logic is not upgradeable.
  • [low] Configurable reward recipient: An egRecipient address and claimEgTokens function suggest a fee or reward stream that is directed by the owner to a configurable recipient.

Contract details

Verified source
No
Bytecode size
11,328 bytes
Upgradeable proxy
No
Detected patterns
ownable, return-delta

Pools using Custom pricing hook