Add Aegis hook on base#577
Merged
marktoda merged 1 commit intoMay 22, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Review: hooks/base/0x8f29bd5c8429730fa4c46e6295c4e679ededd0cc.json
Contract: AegisHook on Base (chainId 8453). Source verified on Etherscan.
Flag Verification
Address 0x...d0cc, lowest 14 bits: 0xd0cc & 0x3fff = 0x10cc = 01 0000 1100 1100
| Bit | Flag | Expected | File |
|---|---|---|---|
| 13 | beforeInitialize | false | false ✓ |
| 12 | afterInitialize | true | true ✓ |
| 11 | beforeAddLiquidity | false | false ✓ |
| 10 | afterAddLiquidity | false | false ✓ |
| 9 | beforeRemoveLiquidity | false | false ✓ |
| 8 | afterRemoveLiquidity | false | false ✓ |
| 7 | beforeSwap | true | true ✓ |
| 6 | afterSwap | true | true ✓ |
| 5 | beforeDonate | false | false ✓ |
| 4 | afterDonate | false | false ✓ |
| 3 | beforeSwapReturnsDelta | true | true ✓ |
| 2 | afterSwapReturnsDelta | true | true ✓ |
| 1 | afterAddLiquidityReturnsDelta | false | false ✓ |
| 0 | afterRemoveLiquidityReturnsDelta | false | false ✓ |
All flags match getHookPermissions() in source and the bitmask. ✓
Properties Verification
- dynamicFee: true —
_beforeSwapcallsDYNAMIC_FEE_MANAGER.prepareSwap()and returnsactiveFee | LPFeeLibrary.OVERRIDE_FEE_FLAG. ✓ - upgradeable: false — No proxy, no delegatecall, all dependencies are
immutable.source_meta.jsonconfirms"proxy": false. ✓ - requiresCustomSwapData: false — The
bytes calldatahookData in_beforeSwapis unnamed and entirely unused; swaps function correctly with empty hookData. ✓ - vanillaSwap: false — Both
beforeSwapReturnsDeltaandafterSwapReturnsDeltaare true (hook charges input-currency fees), and dynamic fee override is applied on every swap. ✓ - swapAccess: "none" —
_beforeSwaphas no access control gate. Thesender == AEGIS_ENGINEbranch only caps the fee, it does not revert or block. The contract inheritsPausablebut pausing is an owner admin action, not per-swap access control. ✓
Metadata Verification
chainId: 8453matches"base"in chains.json. ✓verifiedSource: truematches"verified": truein source_meta.json. ✓name: "Aegis"— a clean abbreviation of the verified contract nameAegisHook/ NatSpec@title AegisHook. No promotional language. ✓description— Factually accurate. Covers: DynamicFeeManager setting per-swap fees, hook fees collected via BeforeSwapDelta (exactIn) and afterSwap return delta (exactOut), periodic full-range reinvestment via AegisEngine with cooldown, oracle observation cardinality growth management, and post-swap notifications to LimitOrderManager and OracleManager. All claims substantiated by source logic. ✓
All checks pass.
marktoda
approved these changes
May 22, 2026
Contributor
marktoda
left a comment
There was a problem hiding this comment.
Bot review verified. Aegis on base (0x8f29...d0cc, same address as 576). Bitmask 0x10cc → afterInitialize, beforeSwap, afterSwap, beforeSwapReturnsDelta, afterSwapReturnsDelta. dynamicFee=true. LGTM.
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
AegisHook charges dynamic swap fees set per-swap by DynamicFeeManager, collects additional hook fees on each swap, and periodically reinvests them as full-range liquidity via AegisEngine. It manages oracle observation cardinality growth and notifies LimitOrderManager and OracleManager after each swap.
Flags
Properties
Warnings
Closes #574