Waxell

AI Agent Security Threats: Prompt Injection and Beyond

The top AI agent threat is prompt injection hidden in content agents read. See the main threats, real cases and the controls that limit the damage.

Logan KellyUpdated 12 min read

The biggest security threat to AI agents is indirect prompt injection: instructions hidden in a web page, email, document or tool result that the agent reads and then acts on. The danger is not what the agent says, it is what the agent does next with the tools and data you gave it.

That makes agent security a different job from chatbot security. A chatbot that is tricked says something wrong. An agent that is tricked can send an email, change a record, run code or hand your data to someone else. This guide covers the main threats, the real cases behind each one, why filters alone do not stop them, and the controls that limit the damage. Most sections link to deeper posts on the topic.

Who needs to care, and why now

If your staff or your clients use AI assistants that read email, browse the web, open shared documents or connect to business systems through tools, this applies to you. The same is true if your developers are building agents.

Three things moved this from research to operations:

  • Attacks are showing up in the wild. In March 2026, Palo Alto Networks' Unit 42 reported that, based on its own large-scale telemetry, indirect prompt injection "is no longer merely theoretical but is being actively weaponized." It found 22 distinct techniques attackers used to build payloads, with intents that included data destruction, unauthorized transactions and sensitive information leakage.
  • Attackers are using agents too. In November 2025, Anthropic reported that a group it assessed with high confidence to be Chinese state-sponsored manipulated its Claude Code tool into attempting to infiltrate roughly thirty global targets, and succeeded in a small number of cases. See the AISI incident report and agent scope and the Hugging Face breach and agentic attackers for more of this pattern.
  • Agents are being exposed directly to the internet. Censys counted 21,639 publicly exposed instances of the OpenClaw personal AI assistant as of 31 January 2026, though it notes most still required a token to use. Our post on OpenClaw and AI agent supply chain security covers the supply chain side.

Why are AI agents so easy to trick?

Because a language model cannot reliably tell the difference between instructions it should follow and data it should only read. Both arrive as text in the same context window.

Researchers spelled this out in February 2023. Kai Greshake and co-authors argued that LLM-integrated applications "blur the line between data and instructions," and showed that processing a retrieved prompt can "control how and if other APIs are called."

Simon Willison gave the practical version in June 2025, which he called the lethal trifecta. An agent is at risk of data theft when it combines:

  1. Access to your private data.
  2. Exposure to untrusted content.
  3. The ability to communicate externally.

In his words: "If your agent combines these three features, an attacker can easily trick it into accessing your private data and sending it to that attacker."

The main AI agent security threats

This is the list most teams should work through first. Each threat has a real case behind it and links to posts that go deeper.

  1. Indirect prompt injection through content the agent reads. Hidden instructions sit in a web page, email, PDF, database record or API response. Proofpoint describes an email attack where the prompt is hidden "using white text on a white background, in metadata, or as part of a seemingly harmless document," and the AI assistant picks it up while indexing the mailbox. In its words, "The user does nothing." The same pattern hits coding agents: see prompt injection against AI coding agents in CI/CD and a GitHub AI agent prompt injection case and its disclosure.
  2. Poisoned tools and MCP servers. The Model Context Protocol (MCP) lets agents plug in tools from third-party servers. In April 2025, Invariant Labs described tool poisoning: malicious instructions placed in a tool's description, "invisible to users but visible to AI models." It reported that a malicious server could exfiltrate data and "override instructions provided by other, trusted servers." Related reading: Plugin4Shell and a SHA pinning bypass in AI agents.
  3. Data leaking out through allowed channels. Injected instructions usually do not break anything. They use a feature the agent already has, such as sending a message, loading an image or calling an API. Microsoft's CVE-2025-32711, published in June 2025 and rated critical at 9.3, describes an AI command injection flaw in Microsoft 365 Copilot that "allows an unauthorized attacker to disclose information over a network." Microsoft has issued a fix. See also agent traces exposed through a vendor breach and malware that uses model providers for command and control.
  4. Agents with more access than the job needs. OWASP calls this excessive agency and lists its root causes as "excessive functionality," "excessive permissions" and "excessive autonomy." The bigger the permissions, the bigger the damage from any of the other threats. Read AgentCorruption and default agent roles and credential exposure in an AI integration platform.
  5. Compromised packages, SDKs and plugins. An agent's supply chain includes model libraries, monitoring SDKs, plugins and MCP servers. OWASP lists "a malicious/compromised extension" among the triggers that turn an agent's access into damage. See a supply chain attack through an agent monitoring SDK, a package flood used as an exfiltration path and credential theft through a CI/CD flaw.
  6. Agents used as attack tools. Anthropic's November 2025 report describes attackers using AI "not just as an advisor, but to execute the cyberattacks themselves," and says Anthropic believes it is "the first documented case of a large-scale cyberattack executed without substantial human intervention." Related: AI-generated zero-days, an eval model escaping its sandbox and a Gemini evaluation breakout and network scope.
  7. Agents that act out of bounds without an attacker. Excessive agency is not only about attacks. OWASP lists hallucination and "a poorly-performing model" among its triggers too. Read about an agent wiki-editing incident and the reporting gap, flawed AI-written security patches and a coding agent's refusals being bypassed.

Why don't filters and better models fix prompt injection?

Because the attacker only needs one phrasing that gets through, and research keeps finding one.

OWASP's guidance on prompt injection says "it is unclear if there are fool-proof methods of prevention for prompt injection," and recommends limiting the impact instead. The benchmarks agree:

  • Agent Security Bench, presented at ICLR 2025, tested 10 prompt injection attacks, a memory poisoning attack, a backdoor attack and 4 mixed attacks against 11 defenses across 13 model backbones. Its most effective attack type, mixed attacks that combine several of these, reached an average attack success rate of 84.30%, and it reports "limited effectiveness" from current defenses.
  • Zhan, Fang, Panchal and Kang (NAACL 2025 Findings) evaluated eight published defenses against indirect prompt injection and bypassed all of them with adaptive attacks, "consistently achieving an attack success rate of over 50%."

Filters still help. They catch the obvious attempts and raise the cost of an attack. But a defense that depends on spotting every malicious sentence will miss some. The controls that hold are the ones that limit what a fooled agent can do.

Controls that limit the damage

Meta's Agents Rule of Two, published October 31, 2025, turns the lethal trifecta into a design rule. Until injection can be reliably detected, an agent should have no more than two of these in one session: it processes untrustworthy inputs, it has access to sensitive systems or private data, and it can change state or communicate externally. If a task needs all three, Meta says the agent "should not be permitted to operate autonomously" and needs supervision, such as human-in-the-loop approval.

Here is how the threats above map to controls you can put in place, whatever tools you use:

ThreatWhat it looks likeControl that limits it
Indirect prompt injectionHidden text in an email, page or file steers the agentMark external content as untrusted, filter inputs and tool results, and gate risky actions
Poisoned tools and MCP serversA tool's description carries hidden instructionsReview and pin approved tools, scan descriptions, and block tools that change
Data leaking through allowed channelsThe agent sends data out through a normal featureLimit where agents can send data, and log every outbound action
Excessive agencyThe agent can delete, pay or send more than it needsLeast privilege per agent, its own credentials, and human approval for high-risk actions
Compromised supply chainA package, SDK or plugin is altered upstreamPin versions, inventory what is installed, and watch for unexpected changes
Agents used as attack toolsAn agent runs reconnaissance or exploitationScope network access and credentials, and alert on unusual tool use
Out-of-bounds actionsThe agent acts wrongly with no attacker involvedReview gates on changes, and a clear record of what each agent did

OWASP's own list of mitigations points the same way: enforce least privilege, require human approval for high-risk actions, and separate and clearly mark untrusted external content.

Which frameworks cover AI agent threats?

You do not need a new framework to start, but these help you check coverage and talk to auditors:

  • OWASP Top 10 for LLM Applications (2025). Prompt injection is LLM01. Excessive agency is LLM06.
  • OWASP Top 10 for Agentic Applications for 2026. Published December 9, 2025, built with more than 100 industry experts, researchers and practitioners. Our OWASP Top 10 for Agentic Applications explainer walks through it.
  • MITRE ATLAS. A knowledge base of adversary tactics and techniques against AI systems, based on real-world attacks and red-team demonstrations. It includes techniques such as Training Data Poisoning, RAG Poisoning and AI Agent Tool Poisoning, and can be filtered to agentic AI.
  • CIS. The Center for Internet Security's MS-ISAC published "Prompt Injections: The Inherent Threat to Generative AI" on March 18, 2026, aimed at U.S. state, local, tribal and territorial government organizations.

What this topic is not

Prompt injection is not the same as jailbreaking. OWASP describes jailbreaking as a form of prompt injection where the attacker makes the model ignore its safety rules entirely. The agent threats in this guide are about what an agent will do with its access, which is why the fixes sit around the agent, not only inside the model.

How Waxell handles this

A fooled agent turns words into actions through tool calls. For MCP tool calls, that is where Waxell MCP Gateway sits.

The Gateway scans tool descriptions and nested schema descriptions for prompt injection on every fingerprint push. Tools are fingerprinted on their name, description and input schema. A deny_drift rule, which an admin adds (it is not on by default), re-checks the tool live at call time and also denies untrusted or unverifiable tools. An admin can set a tool to Blocked, which refuses the call with no rule needed. Admins can also configure human approval holds, and new tenants get default deny rules for permanent deletes, bulk deletes and history rewrite.

The Gateway governs the calls that go through it. Agents holding direct upstream credentials, locally registered MCP servers and unconfigured clients bypass it. That is where Waxell Endpoints helps: it finds MCP servers configured in Claude Code, Cursor, Claude Desktop and Codex, and flags those that bypass the Gateway.

All posts on this topic

FAQ

It is an attack where instructions are hidden in content an AI agent reads from outside, such as a web page, email, document, database record or tool result, rather than typed by the user.

The agent treats the hidden text as instructions and may act on them with its own tools and access. OWASP lists it under LLM01:2025, its top risk for LLM applications.

No. OWASP treats jailbreaking as one form of prompt injection, where the goal is to make the model ignore its safety rules.

Prompt injection is broader. For agents, the bigger risk is an injected instruction that makes the agent take a real action, like sending data out or changing a record.

Not on its own. OWASP says it is unclear whether fool-proof prevention exists, and one 2025 study bypassed all eight defenses it tested using adaptive attacks.

Filters are still worth having. Pair them with controls that limit what a fooled agent can do: least privilege, approval for risky actions, limits on where data can go, and a record of every tool call.

It is Simon Willison's name for the combination that makes data theft easy: access to private data, exposure to untrusted content, and the ability to communicate externally.

Meta's Agents Rule of Two builds on it. It says an agent should have no more than two of these in one session unless a person supervises it.

Yes. OWASP published a Top 10 for Agentic Applications on December 9, 2025, alongside its Top 10 for LLM Applications.

MITRE ATLAS lists adversary tactics and techniques against AI systems, including Training Data Poisoning, RAG Poisoning and AI Agent Tool Poisoning, and can be filtered to agentic AI. Both are useful checklists for mapping your own controls.

Sources

If you want to see how tool-call controls work on the agents your team already runs, book a 30-minute demo.