AI Security series: the OWASP Top 10 for LLM Applications (2026) · a long video and a Short for each
- Prompt Injection
- Sensitive Information Disclosure (this post)
- Excessive Agency
- Supply Chain
- Data and Model Poisoning
- Unbounded Consumption
- Misinformation
- Hidden Context Exposure
- Vector and Embedding Weaknesses
- Improper Output Handling
Sensitive information disclosure is number two on the OWASP Top 10 for LLM Applications 2026, and OWASP says it's the entry where practitioner opinion and the incident record agree most closely. This guide covers the four ways AI systems leak data, three real cases, and the controls that matter most.
What counts as disclosure
OWASP's LLM02:2026 entry defines it as an LLM-integrated system exposing confidential, regulated, privileged or proprietary data through a channel that wasn't authorised. The important word is channel. It isn't only the chat answer:
- the answer and the model's reasoning trace,
- tool-call arguments (what the model sends to other systems),
- retrieved chunks from a search index,
- logs, traces and telemetry, which many observability tools record in full by default,
- embeddings (vectors can be inverted back into text),
- observable properties: response length, timing, confidence scores, cache behaviour.
Protected information includes personal data, health and financial data, credentials and API keys, trade secrets, model weights and privileged communications.
Four ways AI systems leak
| Phase | What happens | Example |
|---|---|---|
| Training | The model memorised data and reproduces it | Divergence attacks extracting training text |
| Inference (context) | The model was given data at run time and passes it on | An assistant summarises a file the user shouldn't see |
| Pipeline | Copies end up in logs, fine-tunes, vendors | Full prompts stored in an observability tool |
| Observation | Facts are inferred without seeing content | Topic inference from encrypted response sizes |
OWASP names two structural failures behind most incidents:
- Oversharing upstream. Search indexes built from drives and knowledge bases with legacy permissions. The model retrieves sensitive data exactly as designed. The fix is the data, not the model.
- Persistence. Once data has shaped model weights, embeddings or adapters, it stays extractable after the source file is deleted.
Real case: ChatGPT, 20 March 2023
OpenAI's own incident report (24 March 2023) explains it precisely:
- ChatGPT cached user information in Redis, using the open-source redis-py client with asyncio and Redis Cluster.
- If a request was cancelled after it was sent but before its response was read, the connection was left holding that response. The next, unrelated request on the same connection could receive it.
- A server change at 1 a.m. Pacific on 20 March increased cancellations. Some users saw other users' chat titles, and possibly the first message of a new conversation.
- For 1.2% of ChatGPT Plus subscribers active during a nine-hour window, another user may have seen their first and last name, email, payment address, card type, the last four digits of the card and its expiry date. OpenAI states full card numbers were never exposed.
Among OpenAI's fixes: redundant checks that data returned from the cache matches the requesting user, a review of logs, and notification of affected users. This wasn't the model misbehaving at all. It was ordinary infrastructure mixing up whose data was whose, in an AI product.
The biggest design mistake: filtering after retrieval
Retrieval-augmented generation (RAG) lets an assistant search company documents and answer from them. The common mistake is to build one index over everything and then try to stop the model from saying what it shouldn't.
OWASP's guidance is to authorise before retrieval: enforce document- and chunk-level permissions inside the index query, so the model only ever receives what this user may read. Post-generation filtering can't undo a chunk that's already in the model's context. For high-sensitivity data, keep separate indexes per tenant or per department.
✗ search(all_documents, query) → model → filter_answer()
✓ search(documents_this_user_can_read, query) → model
Real case: DeepSeek's open database, January 2025
On 29 January 2025, Wiz Research reported a publicly accessible ClickHouse database belonging to DeepSeek, on two hosts, that needed no authentication. It held more than a million log lines, including chat history, secret keys and backend details, and allowed full database control through ClickHouse's web interface. DeepSeek secured it promptly after Wiz reported it.
The model wasn't the problem. The logs around it were. Prompts and completions are sensitive data wherever they're stored: observability platforms, debugging dumps, analytics pipelines and backups.
Real research: models remember training data
In 2023, Nasr et al. showed a divergence attack against ChatGPT: asking it to repeat a single word indefinitely eventually made it switch to emitting memorised training data, at about 150 times the normal rate. OWASP summarises the result as more than 10,000 unique memorised examples for roughly USD 200, and notes that vendor patches have been bypassed repeatedly. Fine-tuned models and LoRA adapters are more extractable than base models.
If you fine-tune: whatever goes into the training set can come back out. Scrub secrets and personal data before training.
How to defend
OWASP organises LLM02 mitigations in three tiers. The foundational tier, for every deployment:
- Govern training and retrieval corpora: know where data came from, classify it, de-duplicate, scrub personal data at ingest.
- Minimise context: send only the fields the task needs. Turn off "attach the whole customer record" by default.
- Authorise before retrieval, inside the index query.
- System-prompt hygiene: no secrets, credentials or regulated data in system prompts.
- Sanitise with classifiers, not regex alone: patterns miss encoded and translated output.
- Query budgets per user and session on sensitive endpoints, to slow enumeration.
- Operational hygiene: scrub logs and traces before they reach observability tools, encrypt, and enforce no-train/no-retain settings technically, not just in a contract.
The hardening tier adds differential privacy for training, vector-store access controls separate from document ACLs, redaction of reasoning traces, side-channel padding, and AI-aware audit logging. The advanced tier covers confidential computing, verifiable erasure and disclosure red-teaming as a release gate.
Scenario (hypothetical): the HR assistant
A company builds an HR assistant. A manager asks it to summarise an employee's file; the file includes medical notes, so the summary does too. Every prompt and answer is also stored in the engineering team's observability tool.
Fixes: - A field allow-list for what the assistant may receive, with medical data excluded before the model sees it. - Retrieval scoped to the manager's own reports. - Redaction before logging, a retention period, and logs readable only by a small group.
Myths vs reality
| Myth | Reality |
|---|---|
| We filter answers for personal data, so we're safe | Filter what goes in; output filters miss reworded or encoded leaks |
| Deleting the file deletes the risk | Not if it's in weights, adapters or embeddings |
| Only the answer matters | Logs, traces, tool arguments and backups are disclosure channels |
| Embeddings are anonymous | Modern inversion reconstructs text from vectors |
Getting started: a checklist
- Map what each AI feature can read, and where prompts and answers are stored.
- Permission checks inside retrieval, per user and per document.
- Field allow-lists for context; nothing extra "just in case".
- Move secrets out of system prompts.
- Logs: redact, restrict access, set retention, check vendor storage settings.
- Fine-tuning: scrub training data first.
- Test cross-user leakage: can one account get another account's data out?
Key takeaways
- AI systems leak through answers, logs, training data and side channels.
- The model can't leak what it never received: authorise before retrieval.
- Fewer fields in, fewer copies kept.
- Some of the biggest AI leaks have been ordinary infrastructure: a cache, an open database.
Glossary
- RAG: retrieval-augmented generation; the app retrieves documents and adds them to the prompt.
- Embedding: a numeric vector representing text, used for search; can be inverted.
- Memorisation: a model reproducing training data verbatim or recoverably.
- Divergence attack: a prompt that pushes a model out of chat behaviour into emitting training data.
- Side channel: information inferred from timing, size or caching rather than content.
- LoRA adapter: a small fine-tuned add-on to a base model.
Sources
- OWASP GenAI Security Project, Top 10 for LLM Applications 2026, LLM02 Sensitive Information Disclosure (source on GitHub), CC BY-SA 4.0
- OpenAI, March 20 ChatGPT outage: here's what happened (24 Mar 2023)
- Wiz Research, Wiz Research uncovers exposed DeepSeek database leaking sensitive information (29 Jan 2025)
- Nasr et al., Scalable extraction of training data from (production) language models (2023)