Angstrom on Ethereum
Uniswap v4 Hook Contract 0x0000000aa8c2fb9b232f78d2b286dc2ae53bfad4 on Ethereum · MEV protection · Verified contract
- Volume (24h)
- $0
- Value locked (TVL)
- $86
- All-time volume
- $2.90K
- Pools using this hook
- 1
- Swaps (24h)
- 0 (0 traders)
- Total swaps
- 76
What it does
Angstrom is a permissioned batch auction hook that lets whitelisted nodes settle signed orders and an arbitrage bundle against Uniswap v4 pools at a uniform price, while distributing LP rewards and collecting protocol fees.
How it works step by step
- Only attested nodes can execute bundles, so ordinary swaps outside the bundle path revert with CannotSwapWhileLocked.
- Settles batches of signed user orders and top-of-block orders at a uniform clearing price using internal balances or direct token transfers.
- Tracks per-position reward growth in beforeAddLiquidity and beforeRemoveLiquidity and pays accrued rewards to LPs on removal.
- Mints a protocol fee claim to a dedicated fee collector contract in afterSwap, which the controller can later withdraw.
- Enforces solvency with bundle delta tracking so that every asset is fully settled or saved before a bundle completes.
- Lets users deposit and withdraw token balances to the contract for use in future bundles.
- Swap behaviour
- Swaps are blocked unless executed within a node-submitted bundle or after an attested empty block. Bundle swaps use an override fee, and afterSwap mints a protocol fee claim to the fee collector while adjusting the returned delta.
- Liquidity behaviour
- beforeAddLiquidity and beforeRemoveLiquidity maintain per-position reward growth checkpoints so that accrued rewards are preserved when liquidity changes. On removal, accrued rewards are paid out to the owner via a sync, transfer and settleFor sequence to the pool manager.
- Fee behaviour
- Bundle fees are set per pool in the config store (capped at 20%). Swaps outside a bundle use an override LP fee taken from the controller-set unlocked fee (capped at 40%). The afterSwap hook mints a protocol fee from swap output to a fee collector contract, and the controller withdraws it.
- Owner & admin controls
- Controller address (set in constructor, changeable via setController by current controller) can configure pools (configurePool, batchUpdatePools, removePool), set unlocked and protocol fees (validated against MAX_UNLOCK_FEE_E6 0.4e6 and MAX_FEE 0.2e6 for bundle fee), pull accrued fees (pullFee), withdraw unlock swap fees (collect_unlock_swap_fees), and add or remove attested nodes (toggleNodes). No pausing, upgrade proxy, or timelock was found in the source excerpt.
Enabled Uniswap v4 callbacks
beforeInitialize, afterInitialize, beforeAddLiquidity, beforeRemoveLiquidity, beforeSwap, afterSwap, afterDonate, afterSwapReturnDelta
beforeInitialize and afterInitialize gate pool creation via the Angstrom config store. beforeAddLiquidity and beforeRemoveLiquidity track reward growth per position and pay out accrued rewards on removal. beforeSwap restricts swaps to bundles executed by an attested node (or a signed empty-block attestation) and returns the unlocked fee as an override. afterSwap mints the protocol fee claim to the fee collector. afterSwapReturnDelta is enabled so the hook can alter the swap delta by the fee amount. afterDonate is enabled but no dedicated donate logic was seen in the excerpt.
Security & trust assessment
Risk level: medium (verified source, high confidence).
Who controls it: The controller can reconfigure pools and fee levels (bounded by hard caps), withdraw accrued protocol fees, and choose which nodes may submit bundles, which in turn determines who may execute swaps. It can also replace itself with a new controller address, so a compromised controller key gives full control of fee parameters and fee withdrawals.
Risk to user funds: Users deposit tokens into the contract to trade (deposit and withdraw) and submit signed orders settled through bundles. Bundle settlement enforces solvency via bundleDeltas, so the hook does not let users lose funds through internal accounting alone, but the controller and permissioned nodes control order flow and fee parameters. The controller can withdraw accrued protocol fees and can pull any token balance that is not tracked as user balance, which is a centralized trust assumption.
Security findings
- [medium] Swaps gated by permissioned nodes: Only nodes toggled on by the controller can execute bundles or submit empty-block attestations. Bundled swaps are the only way to swap while the pool is locked, so trading depends on node availability and the controller's node set.
- [medium] Controller can change fees instantly: The controller can rotate itself via setController and reconfigure any pool's fees within the caps (bundle fee up to 20%, unlocked fee up to 40%). These changes take effect immediately with no timelock.
- [low] Hook holds and moves funds via return deltas: The hook's afterSwap and afterSwapReturnDelta paths let it mint claims and modify swap deltas, and the bundle settlement pulls and pushes tokens from the pool manager on the owner's behalf. Users' deposited balances held in the contract (_balances mapping) are withdrawable by their owners, but the controller can pull any accrued validator fees via pullFee.
- [info] Partial review of a large codebase: The source uses a custom solady-based EIP712 and ERC1271 signature path and transient storage for nonce and order invalidation; no obvious reentrancy path was identified in the excerpt, but the bundle execution logic is large and was only partly reviewed.
Contract details
- Verified source
- Yes (Angstrom)
- Compiler
- solc 0.8.26+commit.8a97fa7a
- Bytecode size
- 24,423 bytes
- Upgradeable proxy
- No
- Detected patterns
- erc6909-claims, moves-currency, return-delta, self-unlock
Pools using Angstrom
- USDC / WETH (Dynamic fee) — 24h volume $0, TVL $86, 0 swaps today