---
title: Threat-model an LLM application that reads customer emails and drafts replies.
url: https://gurkanozkan.ai/learn/questions/lead-td-11/
markdown: https://gurkanozkan.ai/learn/questions/lead-td-11.md
kind: question
role: AI leadership
stage: Technical
difficulty: Hard
json: https://gurkanozkan.ai/api/learn/questions/lead-td-11.json
robots: noindex
---

# Threat-model an LLM application that reads customer emails and drafts replies.

AI leadership · Technical · Hard

## Answer

*Model answer, written in a candidate's voice*

### In short

- Treat inbound email as untrusted input and map the full data flow.
- Identify indirect prompt injection and exfiltration paths through drafts, links, images, and tools.
- Minimise PII, set retention limits, and control access to mail, CRM, and internal systems.
- Use least privilege, human approval, output filtering, redaction, and allowlisted destinations.
- Pin and verify models and packages, keep provenance, and log decisions without storing secrets or excess PII.
- Red-team with adversarial emails, monitor anomalies, and maintain an incident runbook.

### In full

I would start by treating every inbound email as untrusted, attacker-controlled input and by mapping the full flow from mailbox ingestion through parsing, prompt construction, model inference, drafting, human approval, and any send or tool action. The main threats are indirect prompt injection in email bodies or attachments, data exfiltration through generated replies, links, images, or tool calls, and over-permissioned access to mail, CRM, or internal systems. I would require least-privilege access, sandboxed tools, allowlisted destinations, human approval before sending, output filtering and redaction, and short retention for raw emails and drafts with PII minimised and access-logged. I would also pin and verify models and packages, keep provenance, avoid sending secrets or raw customer data to third-party APIs, and log decisions without storing unnecessary PII. Finally I would red-team with adversarial emails and exfiltration attempts, monitor for anomalous drafts or tool use, and have an incident runbook for quarantine, rollback, notification, and review.

*Corrected by an independent AI reviewer.*

## What a strong answer covers

- Indirect prompt injection
- Data-exfiltration paths
- PII handling and retention
- Access control and output filtering
- Supply chain (models, packages) and logging
- Red-teaming and incident response

## Common mistakes

- Treating it as purely an accuracy problem

## Topic guides

- [Privacy and UK data protection for AI systems](https://gurkanozkan.ai/learn/topics/privacy.md)
- [Security for LLM applications and agents](https://gurkanozkan.ai/learn/topics/security.md)
---

*Study material compiled with AI: drafted by a local model (Inkling 2 Mini) from public sources, then checked against those sources by independent AI reviewers (Claude) in November 2026. Not reviewed line by line by a person.*
