bb-methodology
The "3rd eye" for pentesting — reminds agent to understand before assuming, validate before reporting.
Smart contract security audit — 10 DeFi bug classes (accounting desync, access control, incomplete path, off-by-one, oracle, ERC4626, reentrancy, flash loan, signature replay, proxy), pre-dive kill signals (TVL < $500K etc), Foundry PoC template, grep patterns for each class,
Claude Code
$ npx -y skills add Gabson0x/bountyforge --skill web3-audit --agent claude-code
Codex
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a codex -y
Cursor
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a cursor -y
Gemini CLI
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a gemini-cli -y
GitHub Copilot
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a github-copilot -y
OpenCode
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a opencode -y
Windsurf
$ npx skills add Gabson0x/bountyforge --skill web3-audit -a windsurf -y
name: web3-audit description: Smart contract security audit — 10 DeFi bug classes (accounting desync, access control, incomplete path, off-by-one, oracle, ERC4626, reentrancy, flash loan, signature replay, proxy), pre-dive kill signals (TVL < $500K etc), Foundry PoC template, grep patterns for each class, and real Immunefi paid examples. Use for any Solidity/Rust contract audit or when deciding whether a DeFi target is worth hunting.
10 bug classes. Pre-dive kill signals. Foundry PoC template. Real paid examples.
See also: [[Smart Contract Audit]], [[Trust Map]], [[Methodology]], [[A→B Chains]], [[Web3 Bug Classes]], [[Web3 Grep Arsenal]], [[Web3 POC Foundry]], [[Web3 Triage Report]], [[Web3 Hunt Foundation]], [[Code Sleuth]], [[Fizz]], [[Pashov Solidity Auditor]], [[Pashov X-Ray]], [[Lead Ledger]], [[Triage]], [[Report Writing]]
---
> ZKsync lesson: $322M TVL + OZ audit + 750K LOC + 5 sessions = 0 findings. Large well-audited bridges are extremely hard.
1. **TVL < $500K** → max payout capped too low for effort 2. **2+ top-tier audits** (Halborn, ToB, Cyfrin, OpenZeppelin) on simple protocol → bugs already found 3. **Protocol < 500 lines, single A→B→C flow** → minimal attack surface 4. **Formula**: `max_realistic_payout = min(10% × TVL, program_cap)` — if < $10K, skip
**Soft kill:** OZ/ToB/Cyfrin audit on current version + codebase > 500K LOC → expect 40+ hours for maybe 1 finding. Only proceed if bounty floor > $50K AND you have protocol-specific expertise.
**Target scoring (go if >= 6/10):**
---
> "Read ALL sibling functions. If `vote()` has a modifier, check `poke()`, `reset()`, `harvest()`. The missing modifier on the sibling IS the bug."
This single rule explains 19% of all Critical findings.
---
The criticals on audited code are rarely in the code. Rank effort by where bugs live:
**Layer 1 — Deployment config, not contract code (biggest source of criticals on audited code).** The invariant is enforced in Solidity but violated at deploy time:
**Layer 2 — Fork mainnet and run invariant fuzzers.** Simulate the state machine against live state (Foundry fork tests + `invariant_` fuzzing):
**Layer 3 — The integration layer, not the target.** Real tokens with real quirks; a decoder correct for the "canonical" ABI is wrong for the deployed variant:
**Layer 4 — Chase new deployments and upgrades.** The newly added, unaudited contract is where the critical lives (tellers/decoders/adapters). A hardened adapter (bounds added post-finding) means the NEXT one won't be. Watch the deployer for fresh contracts; audit before the program updates scope.
**Layer 5 — Chain a medium into a critical.** 1-wei accounting drift or a rounding direction in `mulDivDown` compounded over N deposits = extractable loss.
**The uncomfortable truth:** if the audited code is sound, the critical is at Layer 1 (config/oracle targets) or Layer 2 (fork-fuzzing `getRate()` against a manipulatable feed) — both need live chain access, not more file reads. When file reads run dry: request deployment addresses + RPC, fork, and fuzz.
---
> #1 Critical bug class — 28% of all Criticals on Immunefi.
Two state variables supposed to stay in sync. One code path updates A but forgets B. Later code reads both and makes decisions based on stale B.
Real Value = A - B If A updated but B isn't → Real Value appears larger → phantom value
**Variant 1: Phantom Yield** (Yeet protocol — 35 duplicate reports)
function startUnstake(uint256 amount) external {
totalSupply -= amount; // decremented BEFORE transfer
// aToken.balanceOf(this) still reflects old value
// yieldAmount = aToken.balanceOf - totalSupply = phantom yield
}**Variant 2: Fast Path Skips State Update** (Alchemix V3)
function claimRedemption(uint256 tokenId) external {
if (transmuter.balance >= amount) {
transmuter.transfer(user, amount);
_burn(tokenId);
return; // EARLY RETURN — cumulativeEarmarked, _redemptionWeight, totalDebt never updated
}
// Slow path: updates all state vars correctly
alchemist.redeem(...);
}**Variant 3: Update Happens in Wrong Order** (Alchemix)
function deposit(uint256 amount) external {
_shaAll-round bug bounty skill for Claude Code — parallelized agents for smart contract audits (EVM, Move, Solana, TRON), web/API security, local tooling orchestration, and submission-ready reports for HackerOne, Bugcrowd, Intigriti & Immunefi.
The "3rd eye" for pentesting — reminds agent to understand before assuming, validate before reporting.
Complete bug bounty workflow — recon (subdomain enumeration, asset discovery, fingerprinting, HackerOne scope, source code…
Analyze EVM smart contracts for storage-safety vulnerabilities that can cause persistent state updates to be lost, overwritten,…
Generate Echidna/Medusa-compatible Solidity fuzz suites from Foundry or Hardhat projects. Trigger on "fizz", "generate fuzz…
Convert English-language properties in PROPERTIES.md (produced by the Fizz skill) into Solidity assertions inside the existing…
Use for authorized security assessment of REST, GraphQL, WebSocket, or SOAP APIs, including discovery, authentication,…
Extract and decrypt Windows DPAPI-protected secrets (Credential Manager, browser logins/cookies, Wi-Fi credentials, KeePass keys)…
Clean and finalize authorized natural-language text intended for readers by auditing suspicious invisible Unicode and rewriting…