potentialpaper

From Untrusted Content to Accepted Instructions: Security Risks of Context Compaction in LLM Agents

Keep the title, authors and abstract in paper.json

potentialpaper · 2026-11-23 20:14 UTC · 6d4be4ad3f8b ·

.potentialpaper/metadata.json modified

+++ b/.potentialpaper/metadata.json
@@ -1,19 +1,5 @@
{
- "layout": 5,
- "identifiers": [
- {
- "scheme": "openreview",
- "value": "rRKveE98VH"
- }
- ],
- "title": "From Untrusted Content to Accepted Instructions: Security Risks of Context Compaction in LLM Agents",
- "authors": [],
- "abstract": "LLM agents use context compaction to continue tasks that would otherwise exceed their\ncontext windows, replacing older history with a model-generated summary. We show that this\nprocess creates a new attack surface in agent harnesses: a prompt injection can persist into\nthe compaction summary, reframed as part of the user's task. Across ten models evaluated on a set of 140 tool-using histories, summaries present injected instructions as goals, constraints, or next steps of the task in 18--45% of cases, often omitting the\ninjection's original provenance and sometimes misattributing it to the user or system. When\nframed in this way, agents follow these injected instructions in 25--83% of their next\nresponses. In a separate evaluation with executable tools, agents carry out attacker requests\nwhile still completing the user's task. Changing the role in which the summary is delivered\n(e.g., user vs.\\ system vs.\\ tool) provides little protection in our tests, but changing the\ncompaction prompt to separate user goals from tool observations reduces attack success from\n24% to 5% across four models. This work identifies compaction as a critical security boundary\nin agent harnesses, characterizes how the vulnerability arises, and demonstrates a possible defense.",
- "year": 2027,
- "venue": "ICLR 2027 (under review)",
- "source": "openreview",
- "license": {
- "metadata": "CC0-1.0",
- "abstract": "CC0-1.0"
- }
+ "layout": 6,
+ "kind": "paper",
+ "key": "5ac1fe34-b1da-494a-828f-aab1c0381f2e"
}

paper.json added

+++ b/paper.json
@@ -0,0 +1,9 @@
+{
+ "title": "From Untrusted Content to Accepted Instructions: Security Risks of Context Compaction in LLM Agents",
+ "authors": [],
+ "abstract": "LLM agents use context compaction to continue tasks that would otherwise exceed their\ncontext windows, replacing older history with a model-generated summary. We show that this\nprocess creates a new attack surface in agent harnesses: a prompt injection can persist into\nthe compaction summary, reframed as part of the user's task. Across ten models evaluated on a set of 140 tool-using histories, summaries present injected instructions as goals, constraints, or next steps of the task in 18--45% of cases, often omitting the\ninjection's original provenance and sometimes misattributing it to the user or system. When\nframed in this way, agents follow these injected instructions in 25--83% of their next\nresponses. In a separate evaluation with executable tools, agents carry out attacker requests\nwhile still completing the user's task. Changing the role in which the summary is delivered\n(e.g., user vs.\\ system vs.\\ tool) provides little protection in our tests, but changing the\ncompaction prompt to separate user goals from tool observations reduces attack success from\n24% to 5% across four models. This work identifies compaction as a critical security boundary\nin agent harnesses, characterizes how the vulnerability arises, and demonstrates a possible defense.",
+ "license": {
+ "metadata": "CC0-1.0",
+ "abstract": "CC0-1.0"
+ }
+}