Prompt injection is an attack where hidden or malicious instructions in user input or external content trick an AI system into ignoring its rules or leaking data.
In a prompt injection, an attacker puts instructions where the model will read them, directly in a chat message or indirectly inside a web page, document or email the AI processes. The model may follow those instructions instead of the developer's.
As AI features gain access to data and tools, prompt injection can lead to data leaks, unauthorised actions or misleading answers. It is listed first in the OWASP Top 10 for LLM applications.
Defences are layered: treating all external content as untrusted, limiting what data and tools the model can reach, separating instructions from data, validating outputs, requiring approval for sensitive actions, and monitoring for unusual behaviour.
Dev Monks checks AI apps for prompt injection risks as part of our AI code security audit, including tool permissions, data exposure and output handling, and recommends practical fixes.
Not completely today, so the goal is to limit what a successful injection can do.
Yes, especially when they read emails, documents or web pages from outside.
Need help with this? See our AI Code Security Audit service.