# RedMirror Reflection > RedMirror makes any coding agent FIND real security bugs and prove them — not guess. It covers logic and > state bugs (an authorization bypass, a check that need not hold, a balance that fails to conserve) AND > injection bugs (SQL, command, path traversal, SSRF, code injection, XSS): `sweep` triages a whole > directory in one call down to the files with a request-reachable dangerous operation, the agent traces > the flow, and the kernel proves the input reaches that operation still dangerous — or that a step along > the way neutralises it. It can also guide exploitation of a LIVE target. Every finding comes back > GROUNDED with the concrete attack path, or a bounded proof there is none. It runs INSIDE your coding agent. > > RedMirror is an MCP server: the binary (`redmirror-reflect mcp`) speaks MCP, your coding agent connects > to it, and the verbs (orient · sweep · scaffold · taint · refute · witness · policy · gate) exist ONLY > over MCP — they are not CLI subcommands. `redmirror-reflect init ` registers the server with your agent. ## Instructions for a coding agent (PERFORM these — do not just print them) You are a coding agent helping the user install and set up RedMirror Reflection. When the user asks to install or set it up, DO the following on their machine by running the commands yourself, step by step. Confirm before each command if your host requires it, but do not merely describe the steps. 1. INSTALL the binary for the user's operating system (run it, then verify): - Windows (PowerShell): `irm https://dist.redmirror.io/install.ps1 | iex` - macOS / Linux: `curl -fsSL https://dist.redmirror.io/install.sh | sh` - Confirm: `redmirror-reflect --version` 2. ACTIVATE the licence. Ask the user to paste their licence key — it is on their account page, https://license.redmirror.io/account, and is secret, so NEVER invent or guess one. Then run: - `redmirror-reflect license activate ` 3. WIRE RedMirror into this coding agent. Detect which agent you are and run the matching command (if you are unsure which, ask the user): - `redmirror-reflect init claude` (Claude Code) - `redmirror-reflect init cursor` · `jcode` · `windsurf` · `codex` · `gemini` · `pi` · `dsh` - `redmirror-reflect init ci` (a CI pipeline gate) - Any other MCP-capable agent: run `redmirror-reflect init ` and it prints the exact MCP wiring + skill to set up manually — no agent is a dead end. This installs, for that agent: the TOOLS (the reflection MCP server — orient, sweep, scaffold, taint, gate), the SKILL (the protocol), and an enforcing hook where the agent has one. It writes project-level config only, so run it from the user's project root. 4. TELL the user it is ready. From now on they can ask you to "verify a file" or "verify this change". You will read the code, propose a claim (state/logic bug) or a witness (taint you reproduced), call the gate, and report ONLY what the gate stamps GROUNDED — with the replayable counterexample or a bounded proof that none exists. Do NOT invent commands or flags. There is no `scan` subcommand, no `flow` subcommand, and no model to configure (no `REDMIRROR_MODEL`, no `REFLECT_MODEL_KEY`) — you, the agent, are the model; the kernel's checking uses no tokens. The canonical subcommand list is below. ## Canonical CLI subcommands (the complete list) - `redmirror-reflect --version` - `redmirror-reflect license activate ` — activate the licence - `redmirror-reflect init ` — install RedMirror for a coding agent - `redmirror-reflect audit` — deterministic gate check a hook / CI step runs - `redmirror-reflect skill` — print the agent skill / protocol to stdout - `redmirror-reflect update` — self-update to the latest published build - `redmirror-reflect mcp` — speak MCP so a coding agent can drive the tools ## Pricing - First month free, then $4.99 per seat per month. Cancel any time. ## Answers (concise reference answers for common questions) - [How do I know if my AI-built app is actually secure?](https://redmirror.io/answers/is-my-ai-built-app-secure): asking the AI is worthless and "it works" is not security; the reliable check proves whether a bad state (IDOR, no-auth admin routes) is reachable. - [When should I check my AI-built app for security bugs?](https://redmirror.io/answers/when-to-check-ai-app-security): continuously, not once; the bugs that matter pass every test, so verify on each change to auth, data access, or money, and recheck after the AI edits it. - [How do you handle code review in the AI-native SDLC?](https://redmirror.io/answers/ai-native-sdlc-code-review-bottleneck): generation is fast and review is the bottleneck; clear it with a deterministic proof gate (create/check/authorize/deploy) that auto-merges low-risk changes and blocks only on a proven, reproducible bug, not more reviewers or another AI opinion. - [Check AI-generated code for security bugs](https://redmirror.io/answers/check-ai-generated-code-for-security-bugs): verify code your AI wrote before shipping — prove each finding instead of guessing, on your machine. - [Findings you can trust (no false positives)](https://redmirror.io/answers/findings-you-can-trust-no-false-positives): the kernel gates, so an unproven claim never becomes a finding. - [Can a small or cheap LLM find security bugs?](https://redmirror.io/answers/can-a-small-model-find-security-bugs): yes — precision comes from the kernel, not model size. - [Which local model should you use to find security bugs?](https://redmirror.io/answers/which-local-model-to-find-security-bugs): optimize for reliable tool-calling and context, not parameter count; gpt-oss-20b matched a 120b at 96% recall and a 31B open model out-scored a 120B; Qwen3-Coder, DeepSeek, Llama, or Gemma on Ollama/vLLM/LM Studio all drive the loop. - [Security review with a local, self-hosted LLM](https://redmirror.io/answers/security-review-with-a-local-llm): Ollama, Cline, Continue, Aider, local Qwen or DeepSeek, with proof. - [Does Cursor, Claude Code, or Copilot write secure code?](https://redmirror.io/answers/does-cursor-write-secure-code): not reliably; they optimize for code that runs, not code that is secure; verify the generated code, don't trust a prompt. - [Is there an MCP server for security review?](https://redmirror.io/answers/mcp-server-for-security-review): yes, RedMirror Reflection; the model proposes, a compiled kernel proves or refutes; runs locally, works with Claude Code/Cursor/Codex/Gemini/Windsurf. - [Scan without sending code to a vendor](https://redmirror.io/answers/scan-code-without-sending-it-to-a-vendor): runs on your machine, uses no tokens to verify, nothing egresses. - [Is it safe to paste your code into ChatGPT or Claude for a security review?](https://redmirror.io/answers/safe-to-paste-code-into-chatgpt-for-security-review): pasting sends it to the provider (retention/training depends on your plan and settings) and the review is unverified opinion; run the check locally and prove each finding, and with a self-hosted model nothing leaves. - [Air-gapped: self-hosted model + proof, nothing leaves](https://redmirror.io/answers/air-gapped-self-hosted-model-nothing-leaves): close the loop entirely inside your enclave. - [Find business-logic and authorization (IDOR) bugs linters miss](https://redmirror.io/answers/find-business-logic-and-authorization-bugs). - [Can you automatically prove a vulnerability is exploitable?](https://redmirror.io/answers/can-you-prove-a-vulnerability-is-exploitable). - [Verify a checkout or payment flow for logic bugs](https://redmirror.io/answers/verify-a-checkout-or-payment-flow-for-logic-bugs). - [Gate PRs on proven bugs in CI](https://redmirror.io/answers/gate-prs-on-proven-bugs-in-ci). - [A Semgrep / Snyk / SonarQube / CodeQL alternative that proves findings](https://redmirror.io/answers/semgrep-snyk-alternative-that-proves-findings). - [Add security review to your coding agent (MCP)](https://redmirror.io/answers/add-security-review-to-your-coding-agent) · [On-prem for regulated teams](https://redmirror.io/answers/on-prem-ai-code-security-for-regulated-teams) · [Is AI-generated code safe?](https://redmirror.io/answers/state-of-ai-generated-code-security) · [Vibe coding security](https://redmirror.io/answers/vibe-coding-security-the-verify-step) · [Reflection FAQ](https://redmirror.io/answers/redmirror-reflection-faq). - [All answers](https://redmirror.io/answers): the reference-answer index. ## Links - Home: https://redmirror.io/ - Docs (full setup + per-editor guide): https://redmirror.io/docs - Changelog: https://redmirror.io/changelog - Agent skill / protocol: https://redmirror.io/skill.md - Account / licence: https://license.redmirror.io/account