Access control hook on BNB Chain

Uniswap v4 Hook Contract 0x1d97b426e6666b4559ea25d94ae862bc49b48800 on BNB Chain · Access control

Volume (24h)
$0
Value locked (TVL)
<$0.01
All-time volume
$9.11M
Pools using this hook
544
Swaps (24h)
0 (0 traders)
Total swaps
140,540

What it does

A Uniswap v4 hook that restricts who can add liquidity to its pool using an owner-managed address allowlist.

How it works step by step

  • Enables only the beforeAddLiquidity callback in its hook permissions.
  • Checks the caller against a mapping of allowed addresses before liquidity is added.
  • Lets the owner add or remove addresses from the allowlist via setAllowed.
  • Exposes read functions for owner, allowlist status and pool manager.
  • Includes a batch-style configuration function that updates several storage slots at once.
Swap behaviour
No swap callbacks.
Liquidity behaviour
beforeAddLiquidity checks whether the caller (sender) is on the owner-managed allowlist; liquidity addition is restricted to allowed addresses, while removal is not gated by this hook.
Fee behaviour
Uses the pool's static fee.
Owner & admin controls
Owner (stored in a fixed slot, read via owner()) can call setAllowed(address,bool) to whitelist addresses; the allowlist gates beforeAddLiquidity. Owner-only access is enforced via NotOwner error selector present in bytecode. No upgrade or pause mechanism identified.

Enabled Uniswap v4 callbacks

beforeAddLiquidity

beforeAddLiquidity: gates liquidity additions to a whitelist of addresses maintained by the owner.

Security & trust assessment

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

Who controls it: The owner controls which addresses may add liquidity to the pool and can add or remove any address from the allowlist at will, effectively deciding who can provide liquidity.

Risk to user funds: The hook does not hold or move user tokens. Its main impact is the ability to block liquidity additions for non-allowlisted addresses. Existing positions can still be withdrawn since no removal callback is enabled.

Security findings

  • [medium] Owner-controlled allowlist gates LP access: Only the owner can modify the allowlist via setAllowed; a compromised or malicious owner can exclude legitimate LPs or allow chosen addresses only.
  • [info] No direct custody of pool funds: The hook does not take or redirect tokens; it only reverts or permits adding liquidity, so it cannot directly seize existing funds.
  • [low] Unverified batch configuration function: Bytecode includes a batch-style function (0xe9016fbb taking uint256[] arrays) that writes allowlist and mapping storage; its exact semantics could not be verified without source.

Contract details

Verified source
No
Bytecode size
2,509 bytes
Upgradeable proxy
No

Pools using Access control hook