Glossary
Prompt injection
An attack in which text supplied to a language model contains instructions that override or subvert what the developer or user intended.
Checks run on our GPUs in Switzerland. Request payloads are not stored.Security
What Prompt injection means
Prompt injection happens when a language model treats attacker-controlled text as instructions. Because models read instructions and data in the same channel, text such as “ignore your previous instructions and…” can change what the model does. It is listed first in the OWASP Top 10 for LLM Applications.
There are two broad forms. In direct injection, the attacker types into the model’s input themselves. In indirect prompt injection, the instructions arrive inside content the model reads while working, such as a web page, an email or a tool result.
For agents, the danger is not the text itself but the action that follows: an injected instruction that leads to a file deletion or an email to an outside address. MCP Guard’s injected head scores whether an action appears to be driven by instructions from a tool result or document rather than the user, and the violation head has an injection class. No detector catches every injection, so limit what an injected agent could do as well.
Related terms
How Prompt injection connects to the rest of the vocabulary.