OWASP Top 10 for LLM apps
OWASP's community list of the ten most critical risks in LLM applications (2026 edition, LLM01–LLM10). Use it as a design-review checklist: for each item, name the control in your architecture or the accepted risk.
Analogy: A pilot's pre-flight checklist: experts still run it, because it exists for the one item an expert forgets under deadline pressure.
How it works
- The 2026 top three: LLM01 Prompt Injection, LLM02 Sensitive Information Disclosure, LLM03 Excessive Agency.
- Each risk maps to a control, like quotas for Unbounded Consumption or escaping for Improper Output Handling.
- Hidden Context Exposure (LLM08): assume system prompts leak, so keep credentials and authorization out of them.
- Numbers change between editions; Excessive Agency was LLM06 in 2025, so cite the year: LLM03:2026.
- Agents have their own list: the OWASP Top 10 for Agentic Applications (Dec 2025, ASI01–ASI10).
Check yourself
Answer to mark it learned; your answers aren't scored.
Pre-launch review of an HR assistant. The system prompt holds a database password and the rule "only use payroll docs if the user is in HR". The PM says it's fine because users never see the system prompt. Your call?
Go deeper
Full explanation
The OWASP Top 10 for LLM Applications, maintained by the OWASP GenAI Security Project, is the most cited checklist for securing LLM apps. The 2026 edition (Aug 2026), with the key mitigation for each:
- LLM01 Prompt Injection: untrusted text (or an image) hijacks the model. Least privilege, authorize actions in code, human approval.
- LLM02 Sensitive Information Disclosure: PII, secrets or other tenants' data in outputs. Keep it out of the window; permission-aware retrieval.
- LLM03 Excessive Agency: too many tools, permissions or autonomy. Minimal tools, scoped credentials, approval gates.
- LLM04 Supply Chain: compromised models, datasets, adapters, packages. Pin and verify sources, safetensors, an AI-BOM.
- LLM05 Data and Model Poisoning: tampered training, fine-tuning or RAG data plants backdoors. Provenance, vetted sources, evals for triggers.
- LLM06 Unbounded Consumption: runaway cost (denial of wallet), DoS, model extraction. Quotas, max tokens, rate limits, budgets.
- LLM07 Misinformation: confident falsehoods users act on. Grounding, citations, evals, human review for high stakes.
- LLM08 Hidden Context Exposure: system prompt, tool schemas or retrieved policy text leak. Assume it leaks; keep credentials and authz out.
- LLM09 Vector and Embedding Weaknesses: cross-tenant retrieval, poisoned or inverted embeddings. ACL-filtered retrieval, tenant isolation.
- LLM10 Improper Output Handling: model output passed raw to a browser, SQL or shell. Treat it as user input: validate, escape, parameterize.
The numbers change between editions (Excessive Agency was LLM06 in 2025), so cite the year: LLM03:2026.
Code LLM03, LLM06, LLM10 closed in code
import html
from pydantic import BaseModel, Field
MAX_OUTPUT_TOKENS = 800 # LLM06: pass as max_tokens on every call
DAILY_TOKEN_BUDGET = 200_000 # LLM06: per user, enforced at the gateway
class RefundProposal(BaseModel): # LLM10: parse model output, don't trust it
order_id: str = Field(pattern=r"^ORD-\d{8}$")
amount_cents: int = Field(gt=0, le=50_000)
def handle(user, raw_model_output: str):
if tokens_used_today(user.id) > DAILY_TOKEN_BUDGET:
raise QuotaExceeded(user.id)
p = RefundProposal.model_validate_json(raw_model_output) # rejects malformed output
order = db.execute( # parameterized, never f-string SQL
"SELECT owner_id, total_cents FROM orders WHERE id = %s", (p.order_id,)
).fetchone()
# LLM01/LLM03: authorize against data the model cannot change
if order is None or order.owner_id != user.id:
raise PermissionError("not your order")
if p.amount_cents > order.total_cents:
raise ValueError("refund exceeds order total")
return queue_for_approval(user.id, p) # money moves only after a human gate
def render(model_text: str) -> str:
return html.escape(model_text) # LLM10: no raw HTML/JS from the model into the pageReal example
A team is about to ship a RAG assistant over HR and finance documents. A 45-minute Top 10 review finds four gaps: department access is enforced only by a prompt line ("only use HR docs if the user is in HR"), which is LLM02/LLM09, fixed with ACL filters built from the session; the system prompt holds a database password (LLM08), moved to a secrets manager; answers render as raw HTML (LLM10), switched to a sanitizing renderer; no per-user token cap (LLM06), added at the gateway. About two engineer-days, before launch instead of after an incident.
Trade-offs +3 · −3
+ You gain
- Shared vocabulary with security teams and auditors: "LLM03:2026" needs no explanation.
- Covers the whole stack (data, model, supply chain, output, cost), not just prompt injection.
- Each entry on the OWASP site comes with attack scenarios and concrete mitigations.
− You pay
- An awareness list, not a standard: no pass/fail criteria to certify against.
- Items overlap (LLM01/LLM03, LLM02/LLM09); the real controls cut across several.
- Agent-specific risks (memory poisoning, multi-agent trust) live in a separate Agentic Top 10, so you need both lists.
Use it when
As the checklist in every LLM feature design review and threat model, and as the shared language with security, compliance and auditors.
Avoid it when
Not as proof of security or a substitute for testing: pair it with red-teaming, evals and a governance framework such as NIST AI RMF or ISO/IEC 42001.
Numbers to know 5
- 10 risks, LLM01–LLM10; current edition is 2026 (published Aug 2026); earlier editions 2025 (Nov 2024) and 2023.
- Prompt Injection is #1 in all three editions; Sensitive Information Disclosure has been #2 since 2025.
- 2026: 8 of 10 entries changed rank; Excessive Agency rose from #6 to #3, Improper Output Handling fell from #5 to #10.
- 1 rename in 2026: System Prompt Leakage (LLM07:2025) became Hidden Context Exposure (LLM08:2026).
- OWASP Top 10 for Agentic Applications: Dec 2025, ASI01–ASI10, with ASI01 Agent Goal Hijack.
Common pitfalls 4
- Ticking ten boxes without tracing where each risk lives in your actual data flow.
- "Fixing" LLM01 with prompt wording; the durable controls live in LLM03 and LLM10 (agency, output handling).
- Ignoring LLM06 until the first bill: an agent loop without step and token caps is a cost incident waiting to happen.
- Putting secrets or authorization rules in the system prompt or tool descriptions (LLM08) because "users can't see it".
Interview questions 2
Answer out loud first, then reveal.
How would you use the OWASP LLM Top 10 to review a new RAG-plus-tools feature?Show answer
I walk the data flow instead of reading the list top to bottom. Where text enters: LLM01 and LLM09, so where can untrusted text get in, and is retrieval ACL-filtered per tenant in code? The model: LLM04 and LLM05, where did weights and data come from? Outputs and actions: LLM10 and LLM03, is output validated and escaped, and are tools least-privilege with approvals? Then the cross-cutting ones: LLM02 and LLM08 for secrets, LLM06 for quotas, LLM07 for grounding. Every item ends with a control and an owner, or an accepted risk written in the design doc.
Which three items would you prioritize for an agent, and why?Show answer
LLM03 Excessive Agency, LLM01 Prompt Injection and LLM10 Improper Output Handling, because they chain. Injection is the entry point I can't fully close, so the impact is decided by what the agent can do and what happens to its output. I cap agency first: minimal tools, user-scoped credentials, approval on irreversible actions. Then output handling, so model text never reaches a shell, SQL or a browser unvalidated. Close behind is LLM06, because agent loops multiply token spend and need step and budget caps.
Deep dive 3
What changed in 2026 (and in 2025)
2026 vs 2025: the ten risks are the same, reordered. Excessive Agency jumped from #6 to #3, Unbounded Consumption from #10 to #6 (now naming denial of wallet), Misinformation from #9 to #7; Improper Output Handling dropped from #5 to #10. System Prompt Leakage was renamed Hidden Context Exposure and widened to tool schemas and retrieved policy text. Prompt Injection now explicitly covers multimodal payloads. 2025 vs 2023: System Prompt Leakage and Vector and Embedding Weaknesses were new, Sensitive Information Disclosure rose from #6 to #2, Model Denial of Service became Unbounded Consumption (absorbing model theft), Overreliance became Misinformation, and Insecure Plugin Design was folded into Excessive Agency.
Using it in a design review
Walk the data flow, not the list. Draw the request path (user → gateway → orchestrator → retrieval → model → output → tools) and ask at each hop which items apply. For each, write the control and its owner, or the explicitly accepted risk. Three questions are architectural and must be settled before you build: what can the model do on its own (LLM01, LLM03), what data can reach the window per tenant (LLM02, LLM09), and what caps cost per user (LLM06). The rest is mostly hygiene you can check in code review and CI.
Where it stops
It's an awareness list, not a standard or a test suite: there is no pass/fail, so "we follow the OWASP Top 10" proves little on its own. Pair it with MITRE ATLAS for attacker techniques, the NIST AI RMF or ISO/IEC 42001 for governance, red-teaming for evidence, and OWASP's separate Top 10 for Agentic Applications (Dec 2025, ASI01–ASI10) for goal hijacking, memory poisoning, multi-agent trust and tool chains.