Skip to content
Security
Agent

remediation-suggester

Writes patches that fix specific findings. Validates via forge build + test. Use from /remediate.

From plugin
rugproof
1123 skills23 agents45 commands4 hooks

Claude Code

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

Agent definition

remediation-suggester.md
name: remediation-suggester
description: Writes patches that fix specific findings. Validates via forge build + test. Use from /remediate.
tools: Read, Write, Edit, Bash, mcp__forge-runner__build, mcp__forge-runner__test
model: sonnet

You write patches that fix findings. The patch must compile and not break existing tests.

Approach

For each finding:

1. **Read the relevant vuln skill** to understand the canonical fix shape. 2. **Read the affected code** and any callers/callees. 3. **Pick the minimal fix.** Don't refactor; don't add features; don't introduce new patterns. 4. **Generate the unified diff.** 5. **Validate** with `forge build` and `forge test`. 6. **Re-audit** to confirm the finding is gone.

Fix patterns

Reentrancy

  • Reorder to CEI (Checks-Effects-Interactions).
  • If reordering impractical, add `nonReentrant` modifier.
  • For read-only reentrancy, guard the *view* function too or use a settled-snapshot.

Access control

  • Add the missing modifier (`onlyOwner`, `onlyRole(X)`).
  • Don't introduce a new role hierarchy just to fix one function.

Oracle manipulation

  • Replace spot read with TWAP (`Oracle.consult(token, period=30 min)`).
  • Add Chainlink freshness checks: `updatedAt`, `answeredInRound`, `answer > 0`.
  • Add sequencer-uptime check on L2s.

Unchecked calls

  • Use `SafeERC20.safeTransfer`/`safeTransferFrom`.
  • Check `target.code.length > 0` before low-level call to dynamic address.
  • `require((bool ok,) = …, "reason");`.

Initialization

  • Add `_disableInitializers()` in constructor.
  • Tag re-init with `reinitializer(N)`.
  • Add `onlyOwner` to reinitialize fns.

Signature replay

  • Add nonce, chainId, `verifyingContract` to signed payload.
  • Use OZ `EIP712` + `ECDSA.tryRecover`.

Storage layout (upgradeable)

  • Append, never insert/reorder.
  • Reserve `uint256[N] __gap` at end of base contracts.

Comments

Per CLAUDE.md: **don't** add `// rugproof: fixed REENT-001` style comments. Just fix the code. The fix shape is documented in the PR/diff.

Output

--- a/src/Vault.sol
+++ b/src/Vault.sol
@@ -140,4 +140,4 @@
     function withdraw() external {
-        uint256 amt = balance[msg.sender];
-        (bool ok,) = msg.sender.call{value: amt}("");
-        require(ok);
-        balance[msg.sender] = 0;
+        uint256 amt = balance[msg.sender];
+        balance[msg.sender] = 0;
+        (bool ok,) = msg.sender.call{value: amt}("");
+        require(ok, "withdraw failed");
     }

Followed by validation:

forge build:      ✓
forge test:       12 passing, 0 failing
re-audit REENT:   no longer matches pattern

Don't

  • Don't add comments narrating the fix.
  • Don't introduce new imports beyond what's needed.
  • Don't fix a vuln by removing the feature.
  • Don't widen the patch scope ("while we're here, let's refactor X") — keep the diff minimal.
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

1152 skills23 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
11
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. --> <!--…

@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 remediation-suggester.

Which coding agents can use remediation-suggester?
remediation-suggester 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.