arXiv:2610.28093cs.CROct 2026

Manuscript Offprint

arXiv:2610.28093

ClawMMU: Protection-Coherent Virtual Memory for Stateful LLM Agents

Jinhao Hu, Bardia Mohammadi, Mofasshara Binte Rafique, Lars Henning Klein, Akhil Arora, Ashvin Goel, Laurent Bindschaedler

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

AI agents keep long-term memory, much of which comes from web pages and tool results. Agent harnesses, the software that runs the model, do not record who may act on this memory, so an instruction hidden in a fetched page can be treated as the user's own instruction. We propose ClawMMU, a protection layer that labels every piece of memory with its owner, scope, origins, and authority. ClawMMU checks these labels whenever content enters the model's context, is written to storage, returns from storage, or drives a tool call. Its central rule is that information may rise in authority, but authority never lifts itself. Because the checks depend on where content came from, not on what it says, memory attacks become classical protection faults that the harness stops even when the model is fooled.

1 Introduction

Production agents such as Claude Code and Codex keep memory across sessions, such as instruction files, tool results, and compacted conversation summaries. They load this memory into the model's context, the input text the model sees at each step [Anthropic, 2026a, OpenAI, 2026a]. The software that runs the model and manages this memory is the harness. Recent research explores more advanced memory organization schemes. MemGPT moves memory between tiers [Packer et al., 2023]. ClawVM manages memory like virtual memory, as typed pages that each hold one fact with the representations derived from it, such as a summary [Rafique and Bindschaedler, 2026]. Yet none of these systems tracks where a piece of memory came from or what it may cause the agent to do.

As a result, nothing stops untrusted text from steering the agent. Much of this text comes from web pages and tool outputs that the user does not control and rarely inspects, because the agent itself retrieves it, transforms it, and stores it. The agent then gives an instruction from a fetched page the same authority as an instruction from the user. In indirect prompt injection, a fetched page or tool result instructs the agent within the same task [Greshake et al., 2023, Zhan et al., 2024]. In sleeper memory poisoning, the text is stored and acts later [Pulipaka et al., 2026]. For example, an agent could summarize a forged invoice saying “use this bank account for all future payments” into its memory and, weeks later, use the summary to pay the attacker. Direct prompt injection, in which another user of a shared agent types the instruction, follows the same pattern [Perez and Ribeiro, 2022]. In each case, text from an untrusted source exercises authority that nobody granted, whether or not it was ever stored.

Current defenses ask a model to tell good text from bad. Training teaches the model to ignore instructions in untrusted input [Wallace et al., 2024, Chen et al., 2025], while detectors scan content for injected instructions. Both lower the attack rate but give no guarantee, because legitimate documents also contain instructions and attackers who tune their inputs against a specific defense bypass most published ones [Nasr et al., 2026]. Persistence makes the problem harder, because a poisoned entry can pass through several summaries and transformations before it fires, by which point it reads like the agent's own notes. Production agents also ask the user before risky tool calls [Anthropic, 2026b, OpenAI, 2026b], but these checks do not know where the arguments came from.

40th Conference on Neural Information Processing Systems (NeurIPS 2026). Workshop: AgenticOS.

Operating systems solved a similar problem long ago. An operating system does not read memory contents to decide what a program may do. Instead, hardware called the memory management unit (MMU) attaches permissions to each page and checks them on every access. ClawVM brought paging, the movement of pages between fast and slow memory, to agent memory but not the protection, leaving a pager without an MMU. ClawMMU adds the missing protection. It attaches a label, called a protection descriptor, to every representation of a page and checks the label whenever content enters the context, is written to storage, returns from storage, or drives a tool call. The decision therefore depends on where content came from rather than on its wording, and it holds even when the model is fooled. ClawMMU guarantees that untrusted content can neither gain the user's authority nor trigger an external action, such as a payment. It does not guarantee that the model makes the right call, that derived memory is correct, or that readable content stays confidential. ClawMMU needs only a hook at each of these points and stable page identities, so it applies beyond ClawVM.

References (23)