Fee sharing hook on Base
Uniswap v4 Hook Contract 0xff72ce0a6ccef6bf93f0027d77f884e2d46ee8c0 on Base · Fee sharing
- Volume (24h)
- $0
- Value locked (TVL)
- $0
- All-time volume
- $0
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 0
What it does
This hook takes a configurable protocol share of swap fees and lets its admins pause trading and JIT liquidity, so traders and LPs depend on those admins behaving as expected; which trades pay more or less cannot be determined from the decoded bytecode.
How it works step by step
- Uses beforeSwap and afterSwap callbacks, with a pausable swap path that can halt swaps when paused
- Maintains a protocol fee share in basis points (protocolShareBps, capped by MAX_PROTOCOL_SHARE_BPS) and a protocolFeeRecipient address
- Supports just-in-time (JIT) liquidity positions keyed by hash, with per-position pause, nonce tracking, and EIP-712 domain signing
- Tracks pending claims and a claim counter, suggesting fees or JIT proceeds are accrued and later claimed
- Can rescue unvaulted tokens and interacts with a vault registry (vaultForAsset, registry) and the pool manager unlock flow (unlock, unlockCallback, take)
- Sets per-fee-tier tick spacing via setFeeTier and tickSpacingOf, and uses a dynamic-fee related before-initialize hook
- Swap behaviour
- beforeSwap and afterSwap are implemented; the beforeSwap path checks the paused state and can revert while paused. The decoded bytecode does not reveal the exact fee or delta logic, so the precise effect on trade pricing cannot be determined.
- Liquidity behaviour
- beforeAddLiquidity is implemented and is used with JIT position bookkeeping (jitPositions, pauseJITPosition, JitPositionAlreadyExists, JitPositionUnknown). Remove-liquidity callbacks are present as views in the selector list but are not registered as enabled permissions.
- Fee behaviour
- A protocol share of swap fees is configured in basis points (protocolShareBps, capped by MAX_PROTOCOL_SHARE_BPS) and sent to protocolFeeRecipient; the fee tier is set via setFeeTier. Exact split mechanics and whether fees are returned as hook deltas cannot be confirmed from decoded bytecode.
- Owner & admin controls
- Owner or role-based admin (AccessControl with DEFAULT_ADMIN_ROLE, grantRole, revokeRole, renounceRole) can pause and unpause the contract, pause individual JIT positions, set protocolShareBps (up to the cap), set protocolFeeRecipient, set fee tiers, and rescue tokens. Ownership and role holders are not identifiable from the bytecode.
Enabled Uniswap v4 callbacks
beforeInitialize, beforeAddLiquidity, beforeSwap, afterSwap
beforeInitialize: validates or configures the pool when it is initialized, including fee tier and tick spacing. beforeAddLiquidity: gates or records JIT liquidity additions. beforeSwap: enforces pause and applies swap-time logic. afterSwap: performs post-swap accounting, likely fee accrual for the protocol share.
Security & trust assessment
Risk level: medium, estimated (decoded bytecode, low confidence).
Who controls it: Role holders with DEFAULT_ADMIN_ROLE or the admin role can pause swaps, change protocol fee share and recipient, set fee tiers, pause JIT positions, and rescue tokens.
Risk to user funds: The hook uses the pool manager unlock and take flow and holds token balances for vaulting and JIT accounting; privileged roles can move unvaulted tokens and pause trading, so user funds are exposed to admin action.
Security findings
- [medium] Admin can change protocol fee share: setProtocolShareBps can raise the protocol share up to MAX_PROTOCOL_SHARE_BPS, which would divert a larger portion of swap fees to the recipient.
- [medium] Admin can redirect fee recipient: setProtocolFeeRecipient allows a privileged role to change where protocol fees are sent.
- [medium] Pause can block swaps and JIT liquidity: The pausable contract and pauseJITPosition can halt swaps or specific JIT positions, affecting user trade execution.
- [medium] Token rescue capability: rescueUnvaultedToken lets a privileged role move tokens held by the hook, which is a centralization risk if the hook holds user or pool funds.
- [info] Unverified source: No verified source is available, so the exact fee math, delta handling and upgrade path are inferred from decoded bytecode only.
Contract details
- Verified source
- No
- Bytecode size
- 20,959 bytes
- Upgradeable proxy
- No
- Detected patterns
- dynamic-fee, erc20, fee-sharing, liquidity-management, mev-protection, moves-currency, ownable, pausable, self-unlock
Pools using Fee sharing hook
- MYRC / USDC (0.05% fee) — 24h volume $0, TVL $0, 0 swaps today