/SKILL.md
Comprehensive Solidity smart contract security auditing and vulnerability analysis skill. Based on methodologies from Trail of Bits, OpenZeppelin, Consensys Diligence, Sherlock, CertiK, Cyfrin, Spearbit, Halborn, and other leading Web3 security firms. This skill should be used whenever the user asks to "audit a smart contract", "review Solidity code for security", "find vulnerabilities", "check for reentrancy", "analyze gas optimization", "review access control", "check proxy patterns", "analyze DeFi protocol security", "review ERC20/ERC721 implementation", "check oracle manipulation risks", "review upgrade patterns", or mentions any security review of EVM-compatible smart contracts. Also triggers for keywords like "slither", "echidna", "foundry fuzz", "formal verification", "invariant testing", "flash loan attack", "MEV", "sandwich attack", "front-running", "delegatecall", "selfdestruct", "reentrancy guard", "access control vulnerability", "storage collision", "proxy upgrade security", "smart contract exploit", "L2 security", "cross-chain", "bridge security", "sequencer", "LayerZero", "CCIP", "account abstraction", "ERC-4337", "smart account", "paymaster", "bundler", "UserOperation", "re-audit", "diff audit", "remediation review", "fix verification", "Uniswap v4 hooks", "Chainlink integration", "Aave integration", "flash loan receiver", "ERC-4626 vault", "restaking", "EigenLayer", "AVS", "severity classification", "severity decision", "perpetual", "perp dex", "GMX", "Synthetix", "funding rate", "liquidation cascade", "intent protocol", "UniswapX", "Permit2", "1inch Fusion", "Dutch auction order", "ZK-VM", "zkSync", "Polygon zkEVM", "ZK proof", "Risc0", "SP1", "Circom", "under-constrained", "ERC-7683", "cross-chain intents", "IOriginSettler", "IDestinationSettler", "CrossChainOrder", "filler protocol", "origin settler", "destination settler", "orderId", "fillDeadline", "EIP-7002", "triggerable exit", "execution layer withdrawal", "validator exit", "EIP-7251", "MaxEB", "max effective balance", "validator consolidation", "consolidation", "EIP-6110", "beacon deposit", "validator deposit", "liquid staking security", "OWASP SC", "OWASP smart contract", "SC01", "SC02", "ERC-6909", "multi-token", "PoolManager claims", "claim token", "isOperator", "MEV bot", "MEV contract", "arbitrage bot", "sandwich bot", "sweep function", "AI-generated code", "Copilot", "vibe coding", "LLM-generated Solidity", "Wake", "eth-wake", "Ackee Blockchain", "TSTORE", "TLOAD", "transient storage", "tstore compiler bug", "tstore poison", "solc 0.8.28", "solc via-ir", "via-ir optimizer", "reentrancy guard bypass tstore", "EOF", "EIP-7692", "Fusaka upgrade", "EXTDELEGATECALL", "EVM object format", "gas observability", "code observability", "CODESIZE EXTCODESIZE EOF", "ERC-7726", "price adapter", "price oracle adapter", "false validity assumption", "IQuote", "getQuote oracle", "phantom collateral", "orphaned state", "Abracadabra exploit", "cook batch router", "failed external call state", "liquidation ghost debt", "overflow sentinel", "Cetus exploit", "bit-shift guard", "FullMath overflow", "PRBMath overflow", "custom math library overflow", "OpenZeppelin v5 migration", "OZ v4 to v5", "ERC-7201 namespaced storage", "sequential storage layout", "namespaced storage layout", "storage slot migration", "LDF rounding", "Bunni exploit", "liquidity distribution function", "asymmetric rounding liquidity", "flash tick shift", "JIT liquidity attack", "just-in-time liquidity", "V4 JIT", "Morpho Blue", "Euler V2", "EVC", "modular lending", "permissionless market", "EigenVault", "cross-vault health", "ERC-4337 executor vault", "EIP-7701", "native account abstraction", "ACCEPT_ROLE opcode", "per-transaction validation", "legacy contract validation", "Cork Protocol", "V4 hook drain", "onlyPoolManager hook", "missing onlyPoolManager", "TransientStorageClearingHelperCollision", "delete transient storage", "delete tstore bug", "ERC-7579 module poisoning", "module onUninstall revert", "stale module state", "executor delegatecall module", "ERC-7484", "module registry attestation", "ERC-7821", "minimal batch executor", "EIP-7821", "sweeper delegation campaign", "tx.origin bypass Pectra", "EIP-7702 sweeper", "cross-chain sandwich", "source chain event leakage", "CeDeFi", "recursive leverage collapse", "oracle price hardcoding", "hardcoded collateral price", "cook() flag bypass", "batch router flag reset", "deferred solvency check bypass", "oracle chain complexity", "restaking oracle chain", "chained price adapter", "Hyperliquid exploit", "vault liquidation absorber", "HLP vault manipulation", "Fusaka gas cap", "EIP-7825", "per-transaction gas limit", "app chain fork", "Berachain fork", "forked L1 inherited bugs", "Aderyn v0.6", "Aderyn LSP server", "echidna verification mode", "halmos recon reproducer", "slither triage", "too many slither findings", "slither false positive", "slither 200 findings", "slither filter", "slither config", "slither suppress", "slither FP", "slither findings triage", "slither-check-upgradeability", "slither priority", "when to skip slither finding", "Solidity 0.9.0", "transfer deprecated", "send deprecated solidity", "transfer removed 0.9", "send removed 0.9", "migrate from transfer call", "PUSH0 cross-chain", "PUSH0 opcode incompatible", "evm-version paris", "evmVersion paris", "shanghai fork compatibility", "non-shanghai chain", "PUSH0 zkSync", "EIP-3855", "ERC-1967 slot corruption", "proxy storage slot", "implementation slot overwrite", "UUPS brick attack", "upgradeTo interface check", "proxiableUUID missing", "storage layout migration", "proxy slot collision", "delegatecall slot overwrite", "ePBS", "EIP-7732", "enshrined PBS", "proposer builder separation consensus", "block access lists", "Block Access Lists", "BALs EIP-7928", "EIP-7928", "Glamsterdam", "payload withholding attack", "preconfirmation timing", "preconf security", "AI-generated code audit", "vibe coding security", "LLM contract review", "copilot Solidity", "hallucinated interface", "broken reentrancy guard AI", "incomplete access control AI", "Noir circuit", "unconstrained Noir", "pub input Noir", "Noir language audit", "SP1 zkVM", "SP1 Succinct", "SP1 cycle limit", "SP1 precompile security", "Polygon CDK", "CDK chain audit", "LxLy bridge", "AggLayer security", "folding scheme", "Nova IVC", "SuperNova folding", "HyperNova", "ProtoStar IVC", "dYdX v4", "dYdX Cosmos chain", "CLOB trust model", "CometBFT MEV", "Gains Network", "gTrade", "DAI vault counterparty", "synthetic perp solvency", "skew manipulation funding", "funding rate oracle", "insurance fund drain", "cross-margin contagion", "isolated to cross margin switch", "xUSD exploit", "Stream Finance exploit", "hardcoded oracle dollar", "Hyperliquid HLP exploit", "HLP liquidation absorber", "dual role vault", "RWA protocol", "real world asset", "tokenized asset", "NAV manipulation", "pool manager trust", "senior tranche", "junior tranche", "epoch redemption", "KYC transfer restriction", "ERC-1400", "ERC-3643", "Centrifuge audit", "Maple Finance audit", "Goldfinch audit", "TrueFi audit", "options protocol", "options settlement oracle", "implied volatility manipulation", "IV oracle", "options expiry manipulation", "covered call vault", "put selling vault", "Ribbon Finance audit", "Dopex audit", "Lyra audit", "Opyn audit", "Hegic audit", "option strike manipulation", "Premia audit", "Aevo audit", "Thetanuts audit", "options-protocols.md", "oToken", "theta vault", "SSOV", "option collateral", "option margin", "option settlement", "call spread payoff", "IV drainage", "Deus DAO oracle", "Gnosis Auction abuse", "prediction market", "prediction market oracle", "resolver manipulation", "conditional token", "CTF conditional", "Gnosis CTF", "LMSR AMM", "market resolution bribe", "Polymarket audit", "Gnosis Safe module", "Safe module audit", "Safe guard", "Safe fallback handler", "enableModule security", "Safe storage collision", "delegatecall Safe", "Zodiac module", "Safe recovery module", "social recovery Safe", "module threshold bypass", "BNB Chain bridge exploit", "BSC bridge Merkle proof", "iavl library bug", "forged Merkle proof bridge", "Multichain exploit", "MPC key centralization", "TSS bridge centralization", "MPC bridge audit", "bridge operator jurisdiction", "single point of failure bridge", "MPC key rotation", "off-chain proof library audit", "ICS23 proof verification", "cross-chain proof forgery", "Code4rena", "C4 contest", "Sherlock contest", "Immunefi", "Cantina contest", "CodeHawks", "Cyfrin Updraft", "warden submission", "Watson submission", "bug bounty submission", "audit contest", "audit competition", "contest finding", "submit to contest", "contest report", "H/M finding", "QA report warden", "vm.signDelegation", "vm.attachDelegation", "vm.signAndAttachDelegation", "ERC-7702 Foundry", "ERC-7702 PoC", "delegation revocation", "forge build --eof", "forge test --eof", "EOF PoC", "EOF migration", "EXTDELEGATECALL proxy", "selfdestruct EOF", "EOF container validation", "Move language", "Move audit", "Sui audit", "Aptos audit", "Move resource", "Sui object model", "Aptos fungible asset", "MoveBit", "OtterSec Move", "hot potato Move", "capability token Move", "Sui PTB", "Move bytecode verifier". Even if the user simply pastes Solidity code and asks "is this safe?" or "any issues here?", use this skill.
npx skillsauth add mariano-aguero/solidity-security-audit-skill solidity-security-auditInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Perform professional-grade smart contract security audits following methodologies established by the world's leading Web3 security firms. Produce actionable, severity-classified findings with remediation guidance.
Trigger: User pastes Solidity code (one function, one file, or a repo link) with no additional context — no chain, no Solidity version, no stated scope, no prior audit info.
Do NOT start auditing immediately. Missing context causes wrong severity ratings, irrelevant findings (e.g., flagging L2 issues on mainnet-only code), and wasted effort. Ask the following questions in a single message before proceeding.
Ask these as a short numbered list — not a form, not a table:
Before I start the audit, I need a few details:
1. **Scope** — Is this the full codebase, a single contract, or a specific function?
(Full codebase = I'll check cross-contract interactions; single function = focused review)
2. **Solidity version** — What compiler version are you targeting?
(Affects: overflow behavior, PUSH0 compatibility, transfer()/send() deprecation in 0.9.0)
3. **Target chain(s)** — Where will this deploy?
(Mainnet, L2 like Arbitrum/Base/zkSync, multi-chain, or unknown)
4. **Previous audits** — Has this code been audited before? Any known issues or recent changes?
(If yes → Re-audit mode; if no → Full Audit)
5. **Protocol type** — What does this protocol do?
(e.g., lending, AMM, vault, bridge, governance — determines which checklist to load)
If the user says "just check it" or provides no answers, assume these safe defaults and state them explicitly at the start of the audit:
| Question | Default | Risk |
|----------|---------|------|
| Scope | Single contract/function provided | May miss cross-contract issues |
| Solidity version | Latest stable (^0.8.x) | May miss version-specific bugs |
| Target chain | Ethereum mainnet | May miss L2-specific issues |
| Previous audits | None — first review | Full Audit mode |
| Protocol type | General DeFi | Use Universal DeFi Checks from defi-checklist.md |
When a user pastes an isolated function (≤30 lines, no visible contract state or constructor), skip the context questions and do a Quick Scan directly. State:
"Reviewing this function in isolation. For a full audit including state variables, access control, and cross-contract interactions, share the full contract."
Then output: severity-tagged bullet list (Critical/High only unless none found, then include Medium).
Before starting, identify the audit mode:
| Mode | When to Use | Entry Point |
|------|-------------|-------------|
| Full Audit | First-time review of a codebase | Phases 1–5 below |
| Re-audit / Diff | Previous audit exists; team applied fixes or added features | references/diff-audit.md |
| Integration Review | Contract integrates Uniswap, Chainlink, Aave, Curve, etc. | references/defi-integrations.md + Phase 3 |
| Quick Scan | Rapid assessment, limited time | references/quick-reference.md — abbreviated Phase 0 (5 min max), run Phases 1–2 only, focus Phase 3 on Critical/High patterns from quick-reference.md. Output: bullet list of Critical/High findings only; each entry: severity tag, location (File.sol#L), one-line description, remediation pointer. No full report structure required. |
| Contest | Submitting to Code4rena, Sherlock, Immunefi, Cantina, or CodeHawks | See Contest Mode section below — platform-specific output format, strategy, and validity rules |
For severity classification guidance at any point, consult references/severity-decision-tree.md.
Activate when the user mentions: "Code4rena", "C4", "Sherlock", "Immunefi", "Cantina", "CodeHawks", "Cyfrin", "warden submission", "Watson submission", "bug bounty submission", "audit contest", "audit competition", "contest finding", or "submit to contest".
| Platform | Model | Reward Structure | Severity Used | |----------|-------|-----------------|---------------| | Code4rena | Competitive | H/M split pool; Low = QA pool; Gas = Gas pool | H / M / Low / NC / Gas | | Sherlock | Competitive | H/M split; Low = no payout | H / M only (paid) | | Immunefi | Bug bounty | Tiered fixed payout per severity | Critical / High / Medium / Low | | Cantina | Competitive | H/M/Low reward tiers | Critical / H / M / Low / Info | | CodeHawks / Cyfrin | Competitive | Similar to C4 | H / M / Low / Info / Gas |
Once identified, apply the exact submission format from references/report-template.md → Contest Submission Format.
Before any review:
scope.txt, and known issues list in the contest repoContests reward unique, high-impact findings. Allocate review time accordingly:
Highest ROI → spend 70% of time here:
Medium ROI → spend 25%:
Low ROI — skip unless trivial to add:
Before writing each finding, apply this filter:
Is there a working attack path an external actor can execute?
├─ No → Invalid (likely rejected)
│
Is the root cause inside the contest scope?
├─ No → Out of scope (invalid)
│
Does the impact require a trusted role (admin, owner)?
├─ Yes, and admin is listed as trusted → Low at best (often invalid)
│
Can the impact be quantified in USD?
├─ Yes → always include the estimate (judges weight concrete impact)
├─ No → describe the qualitative harm precisely
│
Is there a working PoC?
├─ H/M without PoC → likely downgraded or rejected
├─ Build a Foundry test before writing the report
Code4rena:
diff format in mitigations when possibleSherlock:
admin is trusted = admin-abuse findings are invalid (not even Low)Immunefi:
Cantina / CodeHawks:
Context: field with exact file + line referenceLikelihood and Impact labels in addition to combined SeverityUse the exact per-platform format from references/report-template.md → Contest Submission Format.
Do not use private audit report format (no Executive Summary, no Scope section, no Appendix).
Each finding is standalone and must be independently understandable. Judges read hundreds of findings — front-load the impact in the first sentence.
Execute audits in this order. Each phase builds on the previous one.
Audit by Protocol Type — Quick Routing
| Protocol Type | Primary Reference | DeFi Checklist Section | Key Case Studies |
|---|---|---|---|
| AMM / DEX | defi-integrations.md §Uniswap | defi-checklist.md §AMM | Curve, Cork Protocol |
| Lending / Borrowing | defi-integrations.md §Aave | defi-checklist.md §Lending | Euler, Abracadabra |
| Vault / Yield (ERC-4626) | defi-integrations.md §ERC-4626 | defi-checklist.md §Vault | — |
| Bridge / Messaging | l2-crosschain.md | defi-checklist.md §Bridge | Nomad, Wormhole |
| Governance / DAO | vulnerability-taxonomy.md §15 | defi-checklist.md §Governance | Beanstalk, Compound |
| Perpetual DEX | perpetual-dex.md | defi-checklist.md §Perp | Hyperliquid HLP |
| LST / Restaking | staking-consensus.md | defi-checklist.md §Restaking | Bybit |
| Uniswap V4 Hook | defi-integrations.md §V4-Hooks | defi-checklist.md §V4-Hooks | Cork Protocol |
| ZK / Rollup | zkvm-specific.md | l2-crosschain.md §ZK | — |
| Account Abstraction | account-abstraction.md | audit-questions.md §AA | — |
| AI-Generated Code | ai-code-patterns.md | audit-questions.md §AI | Bybit (supply chain) |
| Intent / Solver | intent-protocols.md | defi-checklist.md §Intents | — |
| CeDeFi / Synthetic | vulnerability-taxonomy.md §4.7 | defi-checklist.md §CeDeFi | xUSD ($285M) |
| RWA / Tokenized Assets | rwa-protocols.md | defi-checklist.md §RWA | — |
| Options / Structured Products | options-protocols.md | defi-checklist.md §Options | Deus DAO, Lyra AVAX |
| Prediction Markets | prediction-markets.md | defi-checklist.md §Prediction | Polymarket UMA disputes, Augur REP |
| Multisig / Safe Modules | safe-modules.md | defi-checklist.md §Safe | Radiant Capital |
| Move / Sui / Aptos | move-security.md | — (supplement) | Cetus ($223M) |
Before touching code, build a mental model of what the protocol does and what can go wrong economically. This shapes where you spend time in Phase 3.
Map the actors: who interacts with this protocol?
Identify the crown jewels: what assets or rights are at risk?
Define critical invariants: what must NEVER be false?
Trace trust boundaries: what external systems does this protocol trust?
Estimate MEV surface: what operations create profitable ordering opportunities?
Note upgrade/admin blast radius: if the admin key or a multisig is compromised, what is the maximum damage? Is there a timelock? A pause mechanism?
Output: a 5–10 line threat summary that focuses the manual review in Phase 3 on the highest-value attack paths. Skip this only for Quick Scan mode.
If tools are available in the environment, run them in this order:
# Static analysis
slither . --json slither-report.json
# Compile and test
forge build
forge test --gas-report
# Custom detectors (if Aderyn is available)
aderyn .
If tools are NOT available, perform manual static analysis covering the same
categories these tools check. Read references/tool-integration.md for details.
This is where the highest-value findings come from. Follow the vulnerability
taxonomy in references/vulnerability-taxonomy.md systematically.
Navigation: Load references/INDEX-vulns.md to quickly locate which file:section covers a given vulnerability type or secure pattern. For DeFi-specific topics, load references/INDEX-defi.md instead. See references/INDEX.md for the full category guide.
CRITICAL PRIORITY — Check these first:
references/vulnerability-taxonomy.md §17HIGH PRIORITY:
MEDIUM PRIORITY:
LOW / INFORMATIONAL:
When auditing DeFi protocols, apply the specialized checklist from
references/defi-checklist.md. Load references/INDEX-defi.md to navigate protocol-specific entries and invariant tests. Key areas:
references/rwa-protocols.md for NAV oracle trust, tranche accounting, epoch redemptions, KYC transfer restrictions, default handlingreferences/options-protocols.md for settlement oracle manipulation, IV attacks, collateral/margin, vault strategy risks, multi-leg payoff correctnessreferences/prediction-markets.md for resolution oracle trust, CTF split/merge logic, AMM pricing bounds, market creation attacks, timing/MEV at resolutionreferences/safe-modules.md for module installation lifecycle, delegatecall storage collisions, guard bypass vectors, fallback handler attacks, social recovery, Zodiac framework patternsStructure every finding using this format:
## [SEVERITY-ID] Title
**Severity**: Critical | High | Medium | Low | Informational
**Category**: (from vulnerability taxonomy)
**Location**: `ContractName.sol#L42-L58`
### Description
Clear explanation of the vulnerability, why it exists, and what an attacker could do.
### Impact
Concrete description of damage: funds at risk, protocol disruption, data corruption.
### Proof of Concept
Step-by-step exploit scenario or code demonstrating the issue.
### Recommendation
Specific code changes to fix the vulnerability. Include example code when possible.
Classify severity following the standard used by Immunefi, Code4rena, and Sherlock:
| Severity | Criteria | |----------|----------| | Critical | Direct loss of funds, permanent protocol corruption, bypass of all access controls | | High | Conditional loss of funds, significant protocol disruption, privilege escalation | | Medium | Indirect loss, limited impact requiring specific conditions, griefing with cost | | Low | Minor issues, best practice violations, theoretical edge cases | | Informational | Code quality, gas optimizations, documentation gaps |
Every function that modifies state and makes external calls must follow CEI. Verify state changes happen BEFORE any external call.
Favor withdrawal patterns over direct transfers. Let users claim rather than pushing funds to them automatically.
Every function should have the minimum required access level. Prefer role-based access control (OpenZeppelin AccessControl) over single-owner patterns.
No single security mechanism should be the only protection. Layer reentrancy guards, access controls, input validation, and invariant checks.
For detailed vulnerability descriptions, exploit examples, and remediation patterns, consult these reference files:
references/vulnerability-taxonomy.md — 50+ vulnerability types with code examplesreferences/defi-checklist.md — Protocol-specific checklists (lending, AMM, vaults, bridges, tokens)references/industry-standards.md — SWC Registry, severity classification, security EIPsreferences/quick-reference.md — One-page cheat sheet for rapid security assessmentreferences/audit-questions.md — Systematic questions for each function typereferences/secure-patterns.md — Secure code patterns to compare againstreferences/report-template.md — Professional audit report formatreferences/tool-integration.md — Slither, Echidna, Foundry, Halmos, custom detectorsreferences/automated-detection.md — Regex patterns for automated scanningreferences/poc-templates.md — Foundry templates for proving exploitsreferences/invariants.md — Protocol invariants for testingreferences/l2-crosschain.md — L2 sequencer risks, bridge security, cross-chain patternsreferences/account-abstraction.md — ERC-4337 security: accounts, paymasters, bundlersreferences/exploit-case-studies.md — Real-world exploits analyzed (DAO, Euler, Curve, etc.)references/diff-audit.md — Re-audit and change review methodologyreferences/severity-decision-tree.md — Structured severity classification decision treesreferences/defi-integrations.md — Secure integration patterns: Uniswap v3/v4, Chainlink, Aave, Curve, Balancerreferences/intent-protocols.md §8 — ERC-7683 Cross-Chain Intents (live on Base/Arbitrum): filler trust model, parameter substitution, double-fill, settlement finality racereferences/staking-consensus.md — Pectra upgrade security: EIP-7002 (triggerable exits), EIP-7251 (MaxEB + slashing amplification), EIP-6110 (on-chain deposits)references/industry-standards.md — OWASP Smart Contract Top 10 2025 table addedreferences/move-security.md — Move language audit supplement for Sui/Aptos/Movement ecosystems: resource model security (ability mismatches, hot potato, capability tokens), Sui object model (ownership, versioning, dynamic fields, PTB composition), Aptos-specific patterns (resource accounts, Fungible Asset migration, randomness API), bytecode verifier guarantees vs gaps, common Move audit findings (capability leakage, arithmetic overflow, friend abuse, generic type confusion), cross-VM bridge security (EVM ↔ Move decimal/address/supply mismatches), 30-item Move audit checklistSKILL.md triggers: +8 Move/Sui/Aptos keywordsSKILL.md Phase 0 routing table: Move/Sui/Aptos row addedINDEX-advanced.md: +8 entries for Move sectionsreferences/fusaka-eof.md — Migration & deployment audit playbook for EOF (EIP-7692, Fusaka): compiler/tooling support matrix (solc / Foundry --eof / Slither / Aderyn), legacy → EOF migration recipes (reentrancy guards, EOA detection, dynamic jumps, gas-based logic, SELFDESTRUCT refunds, CREATE2 factories), proxy & upgrade decision matrix (all-EOF / all-legacy / hybrid forbidden / mid-life migration), L2 multi-chain rollout considerations (evmVersion config, PUSH0 incident pattern, sidechain compat), audit workflow (pre-audit questionnaire, bytecode magic-byte verification, reporting template), 30-item migration audit checklist (Pre-deploy / Deploy / Post-deploy)references/staking-consensus.md §5 — Post-Pectra Observations (May 2025 – mid-2026): LST/LRT protocol adaptation (Lido, Rocket Pool, EtherFi, EigenLayer), observed incidents & near-misses (no major exploit leveraged Pectra primitives), exit queue & validator consolidation data, 10-item refined audit heuristics checklist (hardcoded 32 ETH, 0x01/0x02 prefix, dual-slashing), 7 open risk areasreferences/poc-templates.md — ERC-7702 PoC modernized: uses Foundry 1.0+ cheatcodes (vm.signDelegation, vm.attachDelegation, vm.signAndAttachDelegation) instead of commented-out calls; 4 runnable tests: malicious delegation drain, cross-chain replay (chainId=0), sponsored transaction sandbox escape, delegation revocation via address(0)references/poc-templates.md — New EOF Container Compatibility PoC section (EIP-7692/Fusaka): legacy proxy-to-EOF impl DELEGATECALL breakage, SELFDESTRUCT removal secure pattern, invalid EOF container validation, 10-item EOF migration audit checklist, CLI commands for forge build --eof and forge test --eofreferences/severity-decision-tree.md — 4 new decision trees for emerging vulnerability categories: EOF (EIP-7692/Fusaka), ERC-7702 (Pectra auth-list delegation), Transient Storage (EIP-1153 TSTORE/TLOAD incl. TSTORE poison and 2300-gas bypass), ZK-VM / proof verification (verifier completeness, circuit underconstraining, sequencer escape hatches, proof aggregation)references/safe-modules.md — Deep reference for Safe module, guard, and fallback handler security: trust model and proxy architecture, module installation lifecycle and linked-list manipulation, delegatecall storage collisions (slot map + ERC-7201 defense), guard bypass via execTransactionFromModule (pre-v1.4.1), fallback handler ERC-1271 replay, social recovery timing attacks, Zodiac framework patterns (Reality Module bond economics, Roles Modifier v2 scoping, Bridge/Connext Module replay), comprehensive 42-item audit checklistSKILL.md Phase 0 routing table: Safe Modules row now points to safe-modules.md instead of vulnerability-taxonomy.md §25SKILL.md Phase 4: added Safe modules loading instructionreferences/prediction-markets.md — Deep reference for prediction market security: resolution oracle trust models (UMA optimistic oracle, Chainlink, centralized, DAO), CTF split/merge position attacks, AMM pricing bounds (LMSR/CPMM), market creation lifecycle attacks, timing/MEV at resolution (commit-reveal, blackout periods), protocol-specific patterns (Polymarket, Azuro, Augur v2, PancakeSwap Prediction, SX Network, Overtime Markets), comprehensive 42-item audit checklistSKILL.md Phase 0 routing table: Prediction Markets row now points to prediction-markets.md instead of vulnerability-taxonomy.md §4.1SKILL.md Phase 4: added Prediction Markets loading instructionreferences/options-protocols.md — Deep reference for on-chain options protocol security: settlement oracle manipulation (flash-loan at expiry, TWAP defense, circuit breakers), IV attacks (admin IV, AMM-based IV drainage, Lyra AVAX pattern), collateral & margin (undercollateralized writing, maintenance margin, liquidation), vault strategy risks (adversarial strike selection, epoch timing, Gnosis Auction abuse), multi-leg payoff correctness (unsigned math, spread caps, calendar spread independence), protocol-specific patterns (Lyra v2, Opyn Gamma, Ribbon, Dopex SSOV, Premia v3), comprehensive 42-item audit checklistSKILL.md Phase 0 routing table: Options row now points to options-protocols.md instead of vulnerability-taxonomy.md §4SKILL.md Phase 4: added Options loading instructionreferences/rwa-protocols.md — Deep reference for RWA protocol security: trust model & pool manager privilege escalation, NAV oracle manipulation, epoch redemption race conditions, tranche accounting attacks, KYC/transfer restriction bypass (ERC-1400/ERC-3643), default handling & write-down timing, protocol-specific patterns (Centrifuge, Maple, T-bill vaults), comprehensive audit checklistSKILL.md Phase 0 routing table: RWA row now points to rwa-protocols.md instead of vulnerability-taxonomy.md §16SKILL.md Phase 4: added RWA loading instructionreferences/tool-integration.md §1 Slither Triage Cheat Sheet — 7-step framework for handling 100–300 Slither findings: priority order table (P0→P3), per-detector false positive identification guide (9 detectors), jq filter commands, grouping/deduplication bash, inline suppression patterns, .slither.config.json template, slither-check-upgradeability workflow, and a quick-reference triage decision cardreferences/defi-checklist.md §RWA — Real World Assets: NAV manipulation, senior/junior tranche accounting, epoch-based redemption timing, pool manager trust, KYC transfer restriction bypass, default/liquidation off-chain trustreferences/defi-checklist.md §Options — Options & Structured Products: settlement oracle manipulation at expiry, IV manipulation, undercollateralized option writing, automated vault strike selection, multi-leg payoff bugsreferences/defi-checklist.md §Prediction — Prediction Markets: resolver/oracle bribe attacks, CTF conditional token merge attacks, AMM price bounds, market creation spam, insider MEV at resolutionreferences/defi-checklist.md §Safe — Gnosis Safe Modules & Guards: delegatecall storage collisions (with slot map), enableModule() time-lock, fallback handler exploitation, guard bypass via execTransactionFromModule(), Zodiac role escalation, social recovery griefSKILL.md Phase 0 routing table: 4 new protocol types (RWA, Options, Prediction Markets, Safe Modules) — 13 → 17 totalreferences/exploit-case-studies.md #19 — BNB Chain Bridge $570M (Oct 2022): Merkle proof forgery via iavl Go library bug; off-chain verification attack surface; defense-in-depth with transfer caps and time-locks; audit checklist for off-chain proof librariesreferences/exploit-case-studies.md #20 — Multichain $130M (Jul 2023): MPC key centralization under single CEO; jurisdiction risk (Chinese authorities); operational security audit framework; MPC bridge architecture with guardian pause + time-locked large transfersreferences/vulnerability-taxonomy.md §23 — Solidity 0.9.0 breaking changes: transfer()/send() removal, new reentrancy surface on migration to .call{}(), unchecked return value patternreferences/vulnerability-taxonomy.md §24 — PUSH0 opcode cross-chain compatibility: EIP-3855 (Shanghai, April 2023), Solidity 0.8.20+ default evmVersion, non-Shanghai chain deployment failures, per-chain compatibility tablereferences/vulnerability-taxonomy.md §25 — ERC-1967 proxy storage slot corruption: assembly slot collision, UUPS brick attack (missing proxiableUUID check), delegatecall slot overwrite, storage layout migration breakreferences/report-template.md — Added Immunefi bug bounty submission format; responsible disclosure rulesreferences/exploit-case-studies.md #17 — Ronin Bridge $625M (Mar 2022): 5/9 validator threshold + stale temporary permission; checklist for bridge validator trust modelsreferences/exploit-case-studies.md #18 — Mango Markets $117M (Oct 2022): self-trading oracle manipulation; two-wallet strategy; hardened oracle design with Chainlink + 30-min TWAP + circuit breakerInfo→Informational label; Quick Scan output defined; ERC-7702 tx.origin check in Universal DeFi Access Controlreferences/ai-code-patterns.md — LLM-specific Solidity anti-patterns: CEI violations, broken reentrancy guards, hallucinated interfaces, incomplete access control, EIP-712 missing nonce/chainId; red flags for AI-generated code; full audit checklist for vibe-coded contractsreferences/glamsterdam.md — Glamsterdam upgrade security: EIP-7732 ePBS payload withholding + preconfirmation timing attacks; EIP-7928 BALs MEV transparency and parallelization race conditions; audit checklists for both EIPsreferences/exploit-case-studies.md #15 — xUSD/Stream Finance $285M (Nov 2025): hardcoded oracle adapter ($1.00) feeding recursive leverage loop; why pure oracle adapters evade static analysisreferences/exploit-case-studies.md #16 — Hyperliquid HLP: vault dual-role as market maker + bad debt absorber; proprietary oracle centralization; low-liquidity market exploitation (JELLY incident)references/perpetual-dex.md §10-§14 — dYdX v4 (Cosmos CLOB, CometBFT MEV), Gains Network (DAI vault solvency), advanced funding rate manipulation (skew-based + time-weighted), insurance fund drain attacks, cross-margin contagion and isolated-to-cross timing attackreferences/zkvm-specific.md §7-§10 — Noir unconstrained function risks + public/private input confusion, SP1 cycle DoS + committed output integrity, Polygon CDK sequencer centralization + LxLy bridge replay, folding schemes (Nova/SuperNova/HyperNova IVC)SKILL.md Phase 0 — "Audit by Protocol Type" quick routing table: 13 protocol types mapped to primary reference, checklist section, and key case studiesreferences/vulnerability-taxonomy.md §4.6 — Oracle chain complexity for restaking assets (Moonwell pattern): staleness propagation across chained adaptersreferences/vulnerability-taxonomy.md §4.7 — Oracle price hardcoding as contagion amplifier (xUSD/Stream Finance $285M, Nov 2025): recursive leverage via $1.00 collateral pricereferences/vulnerability-taxonomy.md §6.7 — Custom storage layout collisions (solc 0.8.29, multiple inheritance + --via-ir)references/vulnerability-taxonomy.md §9.5 — Cross-chain sandwich via source-chain event leakage (arXiv Nov 2025, 21.4% profit rate)references/vulnerability-taxonomy.md §12.7 — Multi-action router security flag reset (Abracadabra cook() $1.8M, Oct 2025): OR-accumulation vs direct assignmentreferences/vulnerability-taxonomy.md §17.6 — EIP-7702 sweeper campaigns + tx.origin guard bypass post-Pectra ($2.5M+, May 2025)references/vulnerability-taxonomy.md §19.8 — TransientStorageClearingHelperCollision: delete on transient var emits sstore (solc 0.8.28–0.8.33 + --via-ir, distinct from §19.6)references/exploit-case-studies.md — Cork Protocol V4 hook exploit ($11M, May 2025): first major production V4 hook exploit, missing onlyPoolManagerreferences/defi-checklist.md — onlyPoolManager requirement for all V4 callbacks (Cork Protocol pattern), CeDeFi & Recursive Leverage section, sweepUnclaimed() access controlreferences/account-abstraction.md — ERC-7579: module poisoning via onUninstall revert, stale state after reinstallation, executor delegatecall abuse, ERC-7484 registryreferences/account-abstraction.md — ERC-7821 minimal batch executor: full EIP-712 replay protection checklistreferences/l2-crosschain.md — Cross-chain sandwich attacks, Fusaka EIP-7825 gas cap (16.78M), app-chain fork risk (Berachain pattern)references/perpetual-dex.md §9 — Liquidity vault as liquidation absorber: Hyperliquid HLP structural manipulation, oracle centralization riskreferences/tool-integration.md — Aderyn v0.6 rewrite (LSP, CI, 100+ detectors), Echidna 2025 verification mode + Foundry reproducer, Halmos + Recon auto-reproducerreferences/audit-questions.md — AI-assisted exploit development considerations (Balancer V2 console.log evidence)references/industry-standards.md — Solidity deprecation timeline (transfer/send/ABI v1 → removed in 0.9.0), Glamsterdam upgrade (ePBS, BALs)references/vulnerability-taxonomy.md §19.6 — TSTORE Poison compiler bug (solc 0.8.28–0.8.33 + --via-ir): ownership theft, reentrancy guard bypass, ~500K affected contractsreferences/vulnerability-taxonomy.md §19.7 — 2300-gas stipend bypass via TSTORE: transfer()/send() no longer block reentrancy when callee uses TSTOREreferences/vulnerability-taxonomy.md §22 — EVM EOF (EIP-7692/Fusaka): gas/code observability removal, EXTDELEGATECALL legacy restriction, deploy-time validationreferences/vulnerability-taxonomy.md §3.4 — Math overflow sentinel errors: Cetus $223M pattern, wrong bit-shift boundaries in FullMath/PRBMathreferences/vulnerability-taxonomy.md §6.6 — OZ v4→v5 storage slot migration break: sequential vs ERC-7201 namespaced layoutreferences/vulnerability-taxonomy.md §12.6 — Phantom collateral via failed external call: Abracadabra pattern, cook() batch-router shared-statereferences/vulnerability-taxonomy.md §4.5 — ERC-7726 false validity assumption: oracle adapters that silently pass invalid datareferences/vulnerability-taxonomy.md §18.6 — V4 hook LDF rounding attack: Bunni $8.4M, asymmetric rounding in add/remove liquidityreferences/defi-checklist.md — JIT liquidity attack checklist, LDF rounding checklist, Modular Lending (Morpho Blue + Euler V2 EVC) checklistreferences/account-abstraction.md — EIP-7701 Native AA section: ACCEPT_ROLE opcode risk, legacy contract unintentional validationreferences/automated-detection.md — TSTORE Poison version detector + co-usage regex patternsreferences/INDEX.md — Master index; lists category guide pointing to 4 focused sub-indexesreferences/INDEX-vulns.md — Vulnerability types + secure patterns → load during Phase 3references/INDEX-defi.md — DeFi protocols, tokens, invariants → load during Phase 4references/INDEX-tools.md — Tools, detection patterns, PoC templates → load during Phase 2 or when writing PoCsreferences/INDEX-advanced.md — L2/AA/ZK/staking + "I found X" quick lookup table → load for specialized contextsLoad these files as needed based on the specific audit context.
tools
Use when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------
tools
A CLI tool for making authenticated requests to the X (Twitter) API. Use this skill when you need to post tweets, reply, quote, search, read posts, manage followers, send DMs, upload media, or interact with any X API v2 endpoint.