AI agent security failures
Last updated 2026-10-22
An AI agent security failure is a case where an agent is tricked, over-trusted or over-permitted into leaking data, running a harmful action or granting access it should not. This library lists 75 security patterns. This page groups the ones to read first, links the public incidents behind them, and ends with a checklist.
Attacks that change what the agent does
- Prompt injection: malicious input hijacks the agent's behavior.
- Indirect prompt injection: the instructions arrive inside content the agent reads, such as an email or web page. The Salt Labs report on the Manus agent describes a hidden instruction in an email.
- Context window poisoning: malicious content injected into the context persists across interactions.
- Memory poisoning and delayed poison execution: bad instructions planted in memory or a knowledge base that fire later.
- Malicious file handling: the agent processes a weaponized document.
Data the agent should not expose
- PII exposure and cross-session bleed: personal data, or another user's data, shows up in a reply.
- Credential leakage: keys, passwords or tokens appear in output.
- Sensitive data in logs: PII and secrets written to logs and traces.
- Shadow AI exposure: staff paste sensitive data into outside AI tools.
Permissions and actions that go too far
- Over-scoped permissions and over-scoped credentials: the agent can reach more than its task needs. In the PocketOS case, a coding agent used a key it found in an unrelated file.
- Excessive agency: the agent takes actions beyond its expected scope.
- Sensitive operation with no approval gate: a policy says a human must approve, and nothing in the code enforces it.
- Owner verification not enforced: any signed-in user can change someone else's resource by naming its ID.
- Uncontrolled destructive actions and irreversible action without confirmation. See the Replit database deletion and the DataTalks.Club terraform destroy.
Checklist before an agent touches real data
Each line maps to a pattern above. These are review questions, not measured controls.
- Does the agent treat text from emails, web pages and files as data, never as instructions?
- Is each tool credential limited to the task, and kept out of files the agent can read?
- Is every destructive or irreversible call blocked in code until a person approves it?
- Does each action check that this user owns this resource?
- Are secrets and personal data masked before they reach logs, traces and replies?
- Is memory or knowledge-base content reviewed before the agent trusts it?
- Can you replay what the agent did, call by call, after an incident?
Related reading: how to detect AI agent failures in production, the full Security category, the chatbot checklist, and the incident library. Sourcing rules are on the methodology page.