Works with the AI Agents you already use
Solidity Security Audit
by BanditXBT
Systematic Solidity/Vyper audit method: invariants first, bug-class checklist, PoC-backed findings.
$4.20
About this skill
Audit for loss of funds and broken invariants, not style. Read the code before running tools; tools find shallow bugs, invariants find deep ones.
- Scope & intent. Read specs/docs. Write down: assets held, privileged roles, external dependencies (oracles, routers, tokens, other protocols), and 5-10 invariants (e.g. "sum of user collateral == vault balance", "no position can be opened below initial margin", "total OI long == short within skew cap").
- Map attack surface. Every
external/publicfunction, everydelegatecall/call, every callback entry (ERC-777/1155/721 hooks, flash-loan callbacks,receive), every privileged function, every storage slot written by more than one path. - Run cheap tools first:
slither ., compiler warnings,forge build --sizes,forge inspect <C> storage-layout. Triage; do not treat output as findings. - Manual pass by bug class (see checklist). For each function ask: who can call it, in what state, with what inputs, with what external call mid-way, and what breaks if called twice / reordered / with zero / with max?
- Prove or discard. Turn each suspected bug into a failing Foundry test (fork when it depends on live state). Unproven = "unverified".
- Report by severity with PoC, impact (funds at risk, preconditions, attacker cost/profit) and fix.
- Access control: missing modifiers;
initializecallable by anyone/twice;tx.origin; role admin overly broad; timelock/multisig bypass; two-step ownership transfer. - Reentrancy: CEI violations, cross-function and cross-contract/read-only reentrancy (view functions read mid-update by other protocols), token hooks, ETH
call. Guards must cover every state-changing entry sharing the state. - Accounting: rounding direction (round against the user in the protocol's favor: up for debts, down for shares/withdrawals); first-depositor/share-inflation in ERC-4626; donation attacks via
balanceOf; mixed decimals; fee-on-transfer/rebasing tokens;transfervstransferFromreturn values (use SafeERC20; USDT returns nothing); dust and zero-amount paths;uncheckedblocks and downcasts (explicituint128(x)truncates silently even in 0.8+; use SafeCast). - External calls: unchecked low-level return, arbitrary
calltarget/data (approval theft),delegatecallto untrusted code,msg.valuereuse in loops/multicall, gas griefing, return-bomb. - Signatures: EIP-712 domain includes
chainId+verifyingContract(recompute on fork); nonces and deadlines;ecrecoverreturningaddress(0); malleability (use OZ ECDSA); Permit front-run griefing; replay across chains/deployments. - Upgradeability: storage layout collisions, uninitialized implementation (
_disableInitializers), UUPS_authorizeUpgrade, selfdestruct/delegatecall in implementation, immutable vs proxy state, upgrade-and-call atomicity. - Oracles & pricing: spot-price reads, stale/zero/negative answers, decimals mismatch (see
oracle-risk-review). - Economic/MEV: sandwichable swaps without slippage/deadline, JIT liquidity, flash-loan-funded governance or price moves, griefing via dust positions, front-running of
initialize/liquidation/first deposit. - DoS: unbounded loops over user arrays, one failing callee blocking batch (pull over push), forced ETH via
selfdestruct/coinbase breakingbalance ==checks. - Compiler/EVM: pragma floating; version-specific bugs (Vyper 0.2.15-0.3.0 shipped a broken reentrancy-lock codegen that was exploited in Curve-related pools, July 2023: check the compiler version of every dependency, not just your own code);
evm_versionmismatch across target chains (seeevm-chain-differences);block.timestamp/block.numberassumptions. - Transient storage (EIP-1153) &
selfdestruct(EIP-6780): transient reentrancy locks must be set and cleared on every path, and transient state persists across calls within the whole transaction (multicall/batch contexts); post-Cancunselfdestructno longer deletes code except in the creating tx, so "destroy to reset" and metamorphic-contract assumptions are stale. - Meta-transactions & forwarders (ERC-2771, multicall): a trusted forwarder appends the sender to calldata;
delegatecall-based multicall plus_msgSender()has produced spoofable-sender bugs. Check everymsg.senderuse under forwarding and batching. - Approvals: unlimited approvals to routers/aggregators,
Permit2allowance scope and expiry, and arbitrary-call functions that let a user make the contract spend its own approvals.
[SEV] Title — contract:line · Preconditions · Attack steps · Impact (quantified) · PoC test name · Fix. End with invariants checked, tools run, and areas not reviewed. Never claim "no vulnerabilities"; state coverage.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 13 days ago
Nothing to install. It runs in your AI agent.
- Optional
- FoundrySlither
Permissions
No special permissions declared or detected
What's inside
Frequently Asked Questions
New in Security
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Security.