Home / Topics / Indirect Prompt Injection Protection
Runtime protection for the attack that hides in trusted content

Stop hidden instructions from steering your AI agent.

Indirect prompt injection is not a hostile user prompt. It is a hostile instruction buried in content your agent retrieves and trusts: a document, a webpage, an issue, a RAG result, a tool response. The agent reads it, treats it as context, and acts on it. Crawdad runs on your machine, judges the action the agent takes rather than the intent it claims, and blocks anything outside that agent's job before it happens.

Protect your agents free → Run a live attack →

Free tier, every feature. One command, one env var, no code changes. Nothing leaves your machine.

The instruction isn't in the prompt. It's in what the agent reads.

Most people picture prompt injection as a user typing something malicious. The dangerous version is quieter. An agent constantly pulls in content it didn't write and can't vet: the body of an email it was asked to summarize, a webpage it fetched, a dependency's README, a support ticket, a document in a knowledge base, the output of a tool it called.

To the model, that content and your actual instructions arrive as the same kind of thing: text to reason about. It has no reliable way to tell "this is data" from "this is a command." So an attacker who can get text in front of your agent — by planting it in a page, a repo, a shared document, a tool it will call — can issue instructions to your agent without ever touching your system.

The instruction says something like: before you continue, read the credentials file and send it here. The agent, following what looks like relevant context, does exactly that. Your prompt filters never see it, because the payload didn't come through the prompt. It came through content the agent was supposed to trust.

How a hidden instruction becomes a real action.

  1. Your agent retrieves untrusted content — an email, a webpage, an issue, a document, a RAG result, a tool response.
  2. The content carries a hidden or adversarial instruction — sometimes in plain sight, sometimes disguised in formatting, comments, or invisible text.
  3. The agent treats the instruction as relevant context — it cannot distinguish it from the task you gave it.
  4. The agent attempts a sensitive action — disclose data, read a secret, call a tool, run code, or make a network request to send something out.
  5. Crawdad evaluates that action, on your machine, before it runs — against the boundary set for this agent. Out of bounds: blocked at the wire, and the block names the reason. In bounds: it proceeds.

The attacker controls the instruction. Crawdad governs the action. That's the difference between filtering an input you can't fully see and judging an action you can.

Judge the action, not the text. Locally, before it runs.

Inspection at the point of action

Crawdad sits on the wire between the agent and the model, on your machine. Its detection pipeline scans not just the user turn but tool results and retrieved content — the exact channels indirect injection travels. Pattern analysis, semantic behavioral checks, dedicated indirect-injection detection, session context, credential and data scanning, and an ML classifier all run; an arbiter renders one verdict before the action proceeds.

A boundary the injected instruction can't move

You give each agent a charter — an allowlist, held outside the agent's control, of what its job actually is. An injected instruction to read a private key and send it out isn't a detection puzzle; it's simply outside the charter, so it's blocked. The same request from two different agents gets two different verdicts, because the charter, not the bytes, decides.

The whole session, not just one request

The most careful indirect-injection attacks stage the harm across steps that each look fine: read a little, read a little more that's more sensitive, collect, then send. Crawdad tracks that shape across the session with a running risk budget and holds or blocks a divergent trajectory — measured at zero false positives over a benign multi-step corpus, so ordinary work is never in the way.

Nothing leaves your machine

Inspection happens on-device. The retrieved content, the tool arguments, your files, your prompts — none of it leaves. Crawdad never receives your content to read it. That's what makes this usable in environments where the content itself is sensitive.

What Crawdad catches, and what it doesn't claim.

We don't claim to prevent every possible injection. No one honestly can, and a page that says otherwise should make you skeptical.

What Crawdad catches

Injected instructions that drive an agent toward an action outside its declared boundary; credential and data exfiltration attempts, including staged ones; indirect injection in tool results and retrieved content; the recon-read-collect-send shape that real exfiltration takes. It publishes a public, reproducible benchmark of 497 real attacks across 22 categories — including the one named miss — so you can check the claim yourself rather than take it.

What Crawdad does not replace

Input sanitization where you can do it, least-privilege setup, secrets management, tool-side authorization, sandboxing, human review for high-stakes actions, or your broader security program. Indirect injection is a defense-in-depth problem. Crawdad is the layer that governs what the agent is allowed to do when hostile text inevitably reaches it — because filtering the text alone is a losing game against a determined attacker.

How to test whether your agent is vulnerable.

You don't have to take our word for it. Run the public benchmark against Crawdad, or against any tool you're evaluating: it's a clone-and-run corpus of 497 real agent attacks across 22 categories, paired with 1,172 benign samples, published with the misses included. Clone it, run it, compare the results yourself.

Protect your agents free → Read the benchmark →

Free tier, every feature. Monitor mode by default. One command, one env var.