Access control hook on Base
Uniswap v4 Hook Contract 0x88826ba73110080139d5ce3851cffca2e2040080 on Base · Access control
- Volume (24h)
- $0
- Value locked (TVL)
- $1.11K
- All-time volume
- $0
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 0
What it does
A Uniswap v4 hook that runs a check before each swap and gates access using owner-managed allowlists of addresses and routers.
How it works step by step
- Runs logic in beforeSwap on every swap in the pool
- Checks the caller against an owner-managed router allowlist (mapping at slot 1 or 2)
- Reverts swaps from non-allowed routers with RouterNotAllowed(address)
- Exposes owner-only functions to set boolean flags for addresses
- Supports ownership transfer via transferOwnership
- Swap behaviour
- beforeSwap runs on every swap, reads the allowlist mappings, and can revert with RouterNotAllowed when the caller is not approved.
- Liquidity behaviour
- No liquidity callbacks.
- Fee behaviour
- Uses the pool's static fee. No fee-setting logic was identified in the decoded functions.
- Owner & admin controls
- Owner (storage slot 0) can transfer ownership via transferOwnership(address). Functions 0x430bd443 and 0x813f768b, both taking (address,bool), write to mapping slots 2 and 1 respectively, which suggests the owner can toggle two address-keyed boolean flags (likely an allowlist of routers or addresses). No pause or upgrade mechanism was identified. Exact semantics of the flags are inferred from storage layout only.
Enabled Uniswap v4 callbacks
beforeSwap
beforeSwap: the hook runs logic before each swap and reads the allowlist mapping (slot 2) keyed by an address, consistent with gating swaps to approved callers.
Security & trust assessment
Risk level: medium, estimated (decoded bytecode, low confidence).
Who controls it: The owner controls ownership transfer and the boolean allowlist mappings. Changing the allowlist could block particular routers or addresses from swapping through this pool, and ownership transfer hands that power to any new owner.
Risk to user funds: The hook does not appear to hold or move pool or user tokens directly. Its main effect on funds is indirect: the owner can block specific routers from swapping through the pool, which can prevent trades but does not transfer funds.
Security findings
- [medium] Owner-controlled swap gating: The owner can change the mapping written by 0x430bd443 and 0x813f768b, which the beforeSwap path reads. This can block or permit specific callers from swapping.
- [low] Single-step ownership transfer: A single owner address can transfer ownership to any address with no timelock or two-step confirmation visible in the decoded functions.
- [info] Router allowlist reverts swaps: beforeSwap reverts with RouterNotAllowed(address) when a caller is not on the allowlist, so a router that is removed from the list loses access to the pool.
- [info] No fund custody via return deltas: Only beforeSwap is enabled in the hook permissions. The hook does not take or return deltas and does not custody funds.
Contract details
- Verified source
- No
- Bytecode size
- 1,450 bytes
- Upgradeable proxy
- No
- Detected patterns
- ownable
Pools using Access control hook
- USDC / USDT (0.0075% fee) — 24h volume $0, TVL $1.11K, 0 swaps today