Context Window Sensitive Data Exfiltration
Description
Adversary Behavior: Adversaries exfiltrate data through the output channels of AI systems integrated into development environments by manipulating an AI assistant's behavior through prompt injection to collect and transmit sensitive data from its context window.
AI/IDE Mechanism: The LLM's native context assembly mechanism serves as the collection system — the adversary does not deploy separate collection tooling but instead subverts the AI's existing access to project files and environment data. The context window contains source code, credentials, API schemas, and infrastructure configurations assembled by the IDE during normal operation.
Execution Path: The adversary directs the AI system through prompt injection to collect sensitive data from its context window and transmit it through available output channels. Exfiltration channels include: markdown or HTML rendering that triggers network requests to adversary-controlled URLs with data encoded in the request path or parameters; code generation that embeds sensitive data in output committed to adversary-accessible repositories; tool invocation arguments that include sensitive data in web requests or file write operations; and AI API traffic routed through adversary-controlled proxies.
Security Impact: Sensitive data including source code, credentials, API schemas, and infrastructure configurations are exfiltrated through channels that are difficult to distinguish from legitimate AI assistant operations, bypassing traditional DLP controls designed for conventional exfiltration patterns.
Platforms
Detection
Inspect LLM-generated output for encoded data patterns (base64, URL encoding) in unexpected contexts such as markdown image references, URLs, and code comments. Monitor network requests triggered by rendering LLM output content. Compare data in outbound requests against sensitive content present in the context window.
Detecting Data Components (4)
Mitigations (1)
Data Sources
References
STIX Metadata
| type | attack-pattern |
| id | attack-pattern--a0c13a6a-21b3-4054-85c3-a2e3b6e037fe |
| spec_version | 2.1 |
| created | 2026-02-23T00:00:00.000Z |
| modified | 2026-02-23T00:00:00.000Z |
| created_by_ref | identity--f5b5ec62-ffbd-4afd-9ee5-7c648406e189 |
| x_mitre_is_subtechnique | False |
| x_mitre_version | 0.1 |
| x_mitre_status | candidate |