Software Securityhome
Fix a findingSearch
Glossary

Prompt injection

Text that makes a language model act against the application’s intent, typed by a user or hidden in documents, web pages, tool results or memory the model processes (OWASP LLM01:2026). Enforce authority outside the model and treat its output as untrusted.

Covered in

Guide

Contain prompt injection at the application boundary

Assume retrieved content can influence model output; enforce data access and consequential actions in components the model cannot authorize for itself.

Guide

Worked threat model: an LLM agent with tools

A complete worked threat model for an LLM agent with tools: the data-flow diagram, the threats from prompt injection, excessive agency, data exfiltration, confused-deputy and memory poisoning, and the mitigations, mapped to the OWASP Top 10 for LLM Applications 2026 and the OWASP Top 10 for Agentic Applications 2026.

Guide

Red-team LLM applications and agents by their effects

A red-teaming method for LLM features and agents: scope the whole system, map attacks to OWASP and MITRE ATLAS identifiers, score trials from observed effects, report rates with confidence intervals and retest on every model or provider change.

Guide

Defend agent memory and context against poisoning (OWASP ASI06)

OWASP ASI06 Memory & Context Poisoning: how an instruction or false fact saved once in agent memory, conversation summaries or a retrieval store steers later sessions, users and agents, and the write, scope, provenance, expiry and recovery controls that contain it.

Guide

Keep secrets and controls out of hidden context (OWASP LLM08:2026)

OWASP LLM08:2026 Hidden Context Exposure, which replaced System Prompt Leakage: why system prompts, tool schemas and retrieved policy text get extracted, what must never be in them, and how to enforce rules where a leak changes nothing.

Guide

Secure AI-assisted development with coding assistants and agents

Treat generated code, suggested packages, repository text and MCP servers as untrusted inputs, and confine coding agents with OS-level isolation and short-lived, narrowly scoped credentials.

All 11 pages that cover Prompt injection in the library

Practice: Local project: Gate model and provider changes on a versioned red-team corpus · Local project: Run model-generated Python in a locked-down container

Find your next answer

Type to search. Search runs in your browser.

Searches run in your browser, but the host can infer them from the index files they load. The address shows your search so you can bookmark or share it.