RepoOps
Open the app
04 / AI Security

AI Security: what did your agents try?

AI Security answers what your coding agents tried and what stopped them. One page shows the verdict on every tool call, the MCP servers they load, the secrets and code alerts in their repositories, and the trust behind each agent's cap. Attacks on your sites live in Production. A part the app does not read says so, never 0.

Last updated

Watch it

30.0 s, captions on. Narration: Microsoft Zira Desktop (provisional voice; an approved narration source is pending).Transcript
Read the narration
  1. 0:00 AI Security shows what your agents tried, and what the policy hook decided.
  2. 0:06 Each tool call passes the local policy hook.
  3. 0:09 A flagged call keeps its rule, never its input.
  4. 0:13 MCP servers lists each server your tools load.
  5. 0:16 A config change clears its review.
  6. 0:19 Secrets and code alerts show what reached the model.
  7. 0:23 Trust bands scale each agent's cap, judged over ninety days.

Synthetic example. Read the guide

1

How to

The RepoOps desktop app with at least one tracked repository.

For repoops.ai: this device bound to a team with brain publishing on, so the hosted page reads the policy log, MCP inventory and caps the desktops publish, and the GitHub connector for code and Dependabot alerts.

  1. Score the machine with repoops readiness.

    It returns a 0 to 100 posture score and the five fixes worth doing first, computed from the coding agents installed, the MCP servers configured, the permission posture and the baseline detectors run in advisory mode over recent sessions. A sixth dimension reads the repository's own agent harness files: a root CLAUDE.md or AGENTS.md short enough to be a map, a check command it names, deny rules and a PreToolUse hook in .claude/settings.json, a turn or budget cap on every loop contract, a handoff file or session log, a CODEOWNERS file, a test script in package.json, a Makefile, pyproject.toml, Cargo.toml or go.mod, and a check that the command the root file names is one those files define. It reads the files and never runs the command. Each check says pass, fail or unknown and names the file it read, and an unknown check counts as not passed. A failed check names the repoops init --harness command that writes the missing starter (a short CLAUDE.md with a check command and a task contract, deny rules and a PreToolUse hook, a capped loop contract, HANDOFF.md, or a .github/CODEOWNERS naming the owner of the GitHub remote); a missing test script or a named command that does not exist is a change you make by hand. It never overwrites a file that exists; it prints what it would have written instead. It runs locally with no account and no network, and it never runs an MCP server to inspect it. The same score is on AI Security's Overview, under Day-one readiness, with Adopt beside each starter template.

  2. List what your agents can reach with repoops mcp-scan.

    It prints every MCP server your coding tools have configured. That list is usually the surprise.

  3. Arm exactly one control.

    Run repoops arm <detector> with the top fix from the score. It prints what it will change and writes nothing until you confirm; --dry-run previews and --yes skips the prompt in a script. Arming installs the gate in .claude/hooks/repoops-enforce/ and registers it. Commit that folder with .claude/settings.json so it resolves for your teammates. repoops disarm moves the detector back to advisory, and repoops disarm --rollback <version> restores an earlier bundle.

  4. Or turn on protection with one switch.

    In the desktop app, the Protection card at the top of the AI Security Overview has one switch, Turn on protection, and Setup links to it. On, it arms three things on this machine together and lists each as on: the credential broker, with its secret stored in the OS keychain and never in a file; the enforcement hook, registered in your own Claude Code settings, with the secret, exfiltration, risky-command and promoted-lesson rules blocking; and the same rules on calls to RepoOps MCP tools. A rule your policy bundle already names keeps its setting. Off undoes all three. It is off on a new install.

  5. Let findings open cases.

    The session signals scan writes durable findings every 15 minutes by default. Set REPOOPS_AIR_OPEN_SCHEDULE=1 in the data directory's .env and a finding at or above REPOOPS_AIR_CASE_MIN_SEVERITY (default high) opens a case.

  6. Open AI Security in the sidebar.

    Both apps open the same page, /v2/ai-security.html. The desktop reads this machine: each tracked repository's policy verdict journal, the MCP configs of your AI tools, the capture findings and what the GitHub source pulled. repoops.ai reads what your bound desktops publish and what the GitHub connector pulls, inside the repositories you may see.

  7. Read the Overview.

    Agent findings lists the open security cases, each opening its case page. Flagged tool calls covers the last 7 days. Since yesterday lists what moved from the start of yesterday, worst first and at most 8: blocked and held tool calls, an MCP server that is new, changed or reviewed, and a credential that went to the model or a GitHub secret scanning alert first read. Site security findings are cards under Site security lives in Production, and Open Production takes you there.

  8. Read Risky commands and enforcement.

    Every tool call passes the local policy hook. Verdicts per tool call lists the flagged ones, a broken rule or a stopped call, with the tool and the rule; the journal never keeps the input. Armed policies shows each rule with its hits, enforced ones blocking and the rest logging. The switches are read only, because a detector changes mode on the Enforcement page one rung at a time. Export policy log downloads the 7 days as NDJSON.

  9. Review MCP servers.

    Inventory has one row per server name across the configs that carry it, with where it keeps a credential (env vars by name, one written into the file, or none). On the desktop a server is reviewed when every config is pinned at its current definition, and a config change clears the pin; Mark reviewed pins it. On repoops.ai Mark reviewed approves the server for the team, owner or admin only, and a later change shows as drift without clearing the approval.

  10. Read the Secrets tab.

    The Key inventory card on top counts the keys tracked, exposed, due or overdue, and their places, and Open the inventory opens the Secrets page. Caught credentials come from three places: a capture finding, which went to the model with the prompt; a flagged call under an exfiltration rule, caught before use when blocked or held; and GitHub secret scanning, which is in the repository. The exposure scan's own sightings join them, and the Matched key column links each row to the key it matched. Code scanning and Dependabot list the open alerts at the last read, each linking to GitHub. A repository GitHub was never read for says not measured. Every key and where it lives, on the Secret scanning card, opens the Secrets page: each key your repositories and platforms hold, every place a copy lives, and the button that rotates it. The secrets guide at /docs/features/secrets walks through it.

  11. Read Agent identity and caps.

    Each agent is banded from its merged pull requests over 90 days: At risk under 0.50 halves its cap, Watch keeps the base, Trusted from 0.80 raises it by half up to the ceiling, and an agent with no merged pull request in the window is not scored. Edit tiers and Pin cap stay disabled, because the bands are fixed and the caps follow them.

  12. Classify a case before you act on it.

    On the case page, use Classify: pick conventional vulnerability, runtime AI attack, assistant or toolchain attack, or not a security incident, enter the detector version (required), then press Record classification. Your name and the time are stored with it.

  13. Read the disclosure clock on a Dependabot case.

    On repoops.ai, a case opened from a Dependabot alert shows Disclosure clock under what GitHub reported. Five rows say when the advisory was published, when RepoOps first stored the alert, when the Dependabot fix pull request opened and merged, and when a production deploy containing the merge went live, each with the hours after the step above. Below them is the total from publication to deploy, or the hours since publication while the fix is not live. A step that has not happened reads not yet. A step GitHub would not answer reads not read, with the reason. The times come from GitHub's advisory, pull request and deployment records, read with your GitHub connector, and a deploy counts only when it succeeded in production and its commit contains the merge. Nothing is estimated.

  14. Approve containment on repoops.ai, then wait for the legs.

    On the hosted case an owner presses Approve containment of the repository. The containment queue shows each leg (the run token, the branch) and reads Revocation requested, not yet confirmed contained until the desktop reports every leg.

2

Use cases

First hour with RepoOps on a new machine

Situation
You installed RepoOps and want to know what your agents can touch before you change anything.
You do
Run repoops readiness, then repoops mcp-scan, then repoops arm with the top fix and confirm the preview.
You see
You have a score with the dimensions behind it, the server list, and one detector enforcing. Every other detector still only reports, so you learn whether a block is survivable in your workflow before you arm a second one.

A protected path changed on a branch

Situation
Changes to protected paths, on AI Security's Risky commands and enforcement tab, reports a modified file under auth against origin/main.
You do
Press View diff on the row. If the change was not meant, press Revert to origin/main and confirm in the panel that opens.
You see
The working-tree file matches the tracked branch and the row is gone after the re-scan. A file committed on this branch is refused with a reason, because a working-tree restore cannot undo a commit.
3

Expected outcome

Workedrepoops readiness prints a score and up to five fixes; a dimension with no data reads unknown and is left out of the average rather than counted as a pass or a fail.
WorkedAI Security shows the flagged tool calls, the MCP servers with their review state, the caught credentials and alerts, and each agent's band and cap, and a part the app does not read says why instead of 0.
WorkedA classified case shows the category, the detector version and who recorded it.
WorkedAfter an approved containment, the hosted queue reads Contained: every leg completed, or Not contained, never contained for a partial run.
Did not workAgent findings is empty.

Next step: No security case is open. Check Session signals for findings and set REPOOPS_AIR_OPEN_SCHEDULE=1. An empty list with the schedule off is a missing source, not a clean bill.

Did not workOn repoops.ai, Risky commands and enforcement says no desktop published a policy log.

Next step: Turn on brain publishing in the desktop app's Settings. A desktop sends its last 7 days of flagged calls at most hourly, and only when they changed.

Did not workThe containment queue still reads Revocation requested, not yet confirmed contained.

Next step: Treat the run as not contained. After an hour with no report the queue says the desktop that performs the revoke may be off or unlinked. Check it is running, then press Re-request containment (Retry containment after a failed report).

Did not workChanges to protected paths says the scan did not run and names origin/main.

Next step: The tracked branch is not fetched locally. Sync the repository, then press Re-scan.

Did not workThe disclosure clock reads not read on every row but First seen by RepoOps.

Next step: GitHub refused the read, and the line under the table says which one. Give the GitHub connector's token read access to Dependabot alerts, pull requests and deployments, or reconnect GitHub on the Connectors page, then reload the case.

Did not workAgent identity and caps says no agent has a cap.

Next step: No base cap is set. Set one in FleetView on the desktop; on repoops.ai the caps come from a bound desktop's fleet control publish.

4

What else to consider

What is armed on install

Nothing. Blocking is opt-in. The policy bundle ships all advisory, the protection switch is off, and the enforcement hook is not registered until you arm a detector or turn protection on. A policy that fails to load means no enforcement, never a blocked call. Enforcement runs at the pre-tool hook of Claude Code, the Codex CLI and the Copilot CLI, plus the MCP seam; there is no network interception. These controls limit what a dangerous tool call can reach and let you stop a run. They do not stop every prompt injection.

Where findings come from

Session signals reads the session transcripts RepoOps already captures, with rules first. The built-in families are credential exposure, risky commands, prompt-injection markers and unverified completion claims; operator rule packs load from the data directory's signals-rules folder. A matched secret is masked in the excerpt. On AI Security, under Session signals on the Risky commands and enforcement tab, you can mute one signal or a whole rule per repository, press Rescan, and export the rows shown as JSON or CSV. With the matching env vars set, new critical or high signals send one batched alert to Slack, PagerDuty or incident.io.

The semantic layer, and when a model reads your sessions

On top of the rules, a semantic layer catches what they miss. Its first tier decodes base64 text and checks it for secrets; it runs by default and never leaves your machine. Its second tier asks a model about paraphrased injection and disguised exfiltration. It runs only once you save a model key on Settings, and then for every tracked repository, sending the raw excerpt to that key's provider and nowhere else. To keep a repository out, pick it under Session signals on AI Security and press Opt out of the model tier under What the scan covers. With no key saved, nothing is sent, and the Semantic layer line says so. Set REPOOPS_SIGNALS_SEMANTIC=0 to turn both tiers off; a REPOOPS_SIGNALS_SEMANTIC_ENDPOINT you set points the model tier at your own model instead, for the repositories named in REPOOPS_SIGNALS_SEMANTIC_REPOS.

How often the detectors catch their own probes

Each detector family has a pack of attack probes in lib/security/redteam/probe-packs.mjs: prompt injection in fetched text, tool poisoning and definition drift in MCP config, credential exposure, risky commands and exfiltration shape. Every pull request to RepoOps runs the packs through the shipped detectors and posts the catch rate per family on the pull request. A lower rate is reported there and never fails the pull request. The figures on the AI Security page come from the committed file website/data/probe-pack-results.json, which npm run probe-packs -- --write rewrites, and a check fails the build when the page and that file disagree. We wrote these probes beside the rules, so a full rate says the rules catch the attacks written down, not every attack.

Protected paths are visibility, not enforcement

The scan diffs the working tree against the branch the repository tracks, scoped to six default categories of sensitive paths (secrets, payments, health data, migrations, auth and the repository brain). A team owner adds paths on repoops.ai under Extra sensitive paths to monitor, and bound desktops merge them in every six hours. Revert overwrites the local file and keeps no copy. The enforcement that a protected path cannot land without review is branch protection and CODEOWNERS on your forge; Make these paths need review drafts the CODEOWNERS file from the paths the scan watched.

What repoops.ai receives

A desktop publishes ids and rule names for its flagged calls, never the command; its MCP inventory with a credential in a config redacted before it leaves the machine; and its caps with each agent's band, never the owner its registry declares. It never sends a working-tree scan, a diff or a secret value. The earlier pages keep their addresses: /team/security still shows the Published security posture parsed from each repository's security.md.

Self-audit of RepoOps itself

RepoOps also audits its own runtime. The Self-audit card on Memory's Wiki tab names a memory recycle flap, a climbing memory footprint or a slower endpoint from measured samples, and proposes a fix you approve. Run a pass now works any time; REPOOPS_SELF_AUDIT_SCHEDULE=1 turns on the schedule. The same passes answer on the API: POST /api/self-audit/run and GET /api/self-audit for the runtime, POST /api/env-audit/run and GET /api/env-audit for build and test logs once terminal capture is on in the account settings.

Cost and egress

No model call. The scans read files and run git on this machine. The publish toggles in Settings are the only RepoOps egress, and both are off by default.