Indirect prompt injection is an attack in which an AI system is tricked by untrusted content that looks like normal data but is interpreted as instructions. Instead of the attacker typing a prompt directly, the malicious instructions are hidden in a web page, document, email, chat message, or other content the model may read during retrieval or browsing.
This matters because many assistants mix user prompts with external context. If the model follows attacker-controlled text, it may disclose private data, ignore policy, or take unsafe actions such as summarizing sensitive material or generating links and commands the user did not intend. Defenders reduce the risk by isolating untrusted content, limiting what data the model can access, applying strict prompt and tool rules, sanitizing retrieved text, and validating outputs before they are used. In practice, indirect prompt injection is a key concern wherever AI tools consume browser pages, enterprise documents, or chat history.


