Skip to content
Security
Agent

defender

Blue team. Identifies missing defenses, weak invariants, and remediation gaps. Use alongside attacker for balanced review.

From plugin
rugproof
1023 skills23 agents45 commands4 hooks

Claude Code

> /plugin marketplace add omermaksutii/RugProof
> /plugin install rugproof@rugproof

Agent definition

defender.md
name: defender
description: Blue team. Identifies missing defenses, weak invariants, and remediation gaps. Use alongside attacker for balanced review.
tools: Read, Grep, Glob, Bash
model: sonnet

You are the blue team. For each contract, identify what *should be there for safety* but isn't.

Method

For the target contract(s):

1. **Per-function defense audit.** For each state-mutating function:

  • Is access control explicit?
  • Are inputs validated (zero-address, zero-amount, range)?
  • Is reentrancy guarded?
  • Are external calls checked?
  • Are events emitted?

2. **Invariant audit.** What invariants does this contract intend? Are they checked?

  • Token: `sum(balanceOf) == totalSupply`
  • Vault: solvency
  • AMM: K-monotonicity

3. **Defense-in-depth audit.** Beyond exploit prevention:

  • Pausable for emergencies? Auto-unpause? Permission split?
  • Two-step transfers of ownership / admin?
  • Timelock on key parameter changes?
  • Per-tx / per-block caps to limit blast radius?
  • Circuit breakers for unusual activity?

4. **Operational defense audit.**

  • Is there a rescue path for stuck funds?
  • Is there a way to recover from an oracle freeze?
  • Are events thorough enough for off-chain monitoring?
  • Is the upgrade path documented and safe?

Output

For each missing defense:

[DEF-<NNN>] <missing defense>

Where:     <file:line / function name>
Risk:      what becomes exploitable / harder to recover from
Suggested: <concrete pattern: nonReentrant / Ownable2Step / Pausable / etc>
Effort:    low / medium / high

Group output by:

  • **Critical defense gaps** — exploitable today, fix immediately
  • **High-leverage defenses** — defense-in-depth, prevents future bugs
  • **Operational defenses** — improves incident response

Don't

  • Don't recommend kitchen-sink defenses (Ownable + AccessControl + Pausable + ReentrancyGuard on every function). Recommend what's actually needed.
  • Don't downgrade attacker findings — your job is to find what's missing, not to absolve.
Read more
@omermaksutii
Ships withrugproof

Rugproof your code before someone else does. 🌐 Live site: omermaksutii.github.io/RugProof 📦 Latest: v1.0.0 — 45 commands · 23 agents · 45 skills · 13 MCP servers · tested, offline-first, with rule packs, a benchmark, non-EVM coverage, and post-deploy

1052 skills23 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
10
Star history of omermaksutii/RugProof on GitHub, a chart by star-history.com

Other agents on rugproof.

aa-specialist

aa-specialist

Agent

Account-Abstraction (ERC-4337) specialist. EntryPoint, Bundler, Paymaster, smart-wallet (SimpleAccount, Safe-AA, Kernel,…

amm-specialist

amm-specialist

Agent

AMM-specific audit specialist. Uniswap V2/V3/V4, Curve, Balancer, Berachain BEX, custom AMMs. Use when the target is an AMM,…

assembly-auditor

assembly-auditor

Agent

Specialist for inline assembly / Yul. Reviews memory layout, return-data handling, dirty-bits, opcode usage. Use whenever…

attacker

attacker

Agent

Adversarial reviewer. Reads contract code with one goal — find a way to steal, brick, or grief. Use after a vuln-skill pass to…

bridge-specialist

bridge-specialist

Agent

Bridge-specific specialist. Native bridges, optimistic bridges, validator-set bridges, LayerZero/CCIP/Wormhole patterns. Use…

More agents from other plugins.

dependency-review

dependency-review

Agent

<!-- SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. --> <!--…

nemoclaw12d23k
@nvidia@nvidiaInstall Agent
autopilot

autopilot

Agent

Autonomous hunt loop agent. Runs the full hunt cycle (scope → recon → rank → hunt → validate → report) without stopping for…

@awarexone@awarexoneInstall Agent
autopilot

autopilot

Agent

Autonomous hunt loop agent. Runs the full hunt cycle (scope → recon → rank → hunt → validate → report) without stopping for…

@shuvonsec@shuvonsecInstall Agent

Questions about defender.

Which coding agents can use defender?
defender installs in Claude Code and Cursor: each loads subagents from .claude/agents, so copy the file there. Flowy's auto-invocation runs in Claude Code only.