arXiv(opens in a new tab)cs.MAOct 2026Cited by 1 paper on PaperVantage

Manuscript Offprint

arXiv:2610.05640

Can CaMeLs Talk? Securing Multi-Agent Systems Against Indirect Prompt Injection Attacks

James Peters-Gill, Avi Semler, Henning Bartsch, Ilia Shumailov, Christian Schroeder de Witt

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

James Peters-Gill

Independent

Avi Semler

University of Oxford

Henning Bartsch

MATS Research

Ilia Shumailov

AI Security Company

Christian Schroeder de Witt

University of Oxford

Abstract—Indirect prompt injection attacks – malicious instructions embedded in content processed by large language models – remain a major obstacle to safely deploying tool-using agents. CaMeL [1] mitigates this threat for an individual agent by separating trusted control flow from untrusted data and enforcing capability-based security policies at runtime. In this work, we investigate whether CaMeL's security guarantees compose in hierarchical multi-agent systems, where agents invoke other agents as tools. We find that CaMeL's guarantees do not compose. We construct a concrete prompt-injection attack that succeeds despite all constituent agents individually operating CaMeL. Our attack exploits the fact that untrusted data can be reinterpreted as trusted input by a downstream agent. We then introduce multi-CaMeL, an agent-to-agent communication protocol that preserves provenance across agent boundaries by separating trusted natural-language instructions from untrusted data passed through a distinct data channel. We evaluate multi-CaMeL's utility on AssetOpsBench and its security-utility trade-off on MultiAgentDojo, a benchmark we develop by extending AgentDojo to the multi-agent setting. We find that multi-CaMeL reduces attack success rate (ASR) to 0.0%, compared with 0.2% for individual-agent CaMeL and 12.9% with no CaMeL. Multi-CaMeL incurs a utility cost, but this cost trends downward as model capability increases and is modest for the strongest models, suggesting that more capable models better accommodate the constraints imposed by the protocol.

I. INTRODUCTION

Prompt injection is a class of attacks in which adversaries craft inputs that cause large language models (LLMs) to follow unintended instructions. When these instructions are supplied directly by the user, this is known as direct prompt injection. In an indirect prompt injection attack, however, the instructions are embedded by an adversary in external content – such as webpages, emails, or documents – that an LLM processes indirectly while performing a task. As LLM-based agents are increasingly deployed in real-world environments and granted access to external data sources, tools, and services, the attack surface for indirect prompt injections expands significantly. An adversary may, for example, place malicious instructions in an email or webpage that is later retrieved and processed by an agent. Prior work has demonstrated concrete indirect prompt injection attacks [2] and documented the prevalence of prompt injection content in the wild, including on publicly accessible webpages and other real-world online sources [3].

Existing defenses against indirect prompt injection can be categorized by the stage of the agent's processing pipeline at which they intervene. Model-level defenses modify the backend LLM at training time – typically through fine-tuning or preference optimization. The model learns to distinguish privileged instructions from lower-authority content and resist following injected instructions [4, 5]. Input-level defenses leave the backend LLM unchanged and instead filter, transform, or restructure its context at inference time. DataFilter, for example, uses a separately trained filtering model, conditioned on both the user instruction and the untrusted data, to remove adversarial instructions while preserving task-relevant content [6]. Similarly, prompt sanitization techniques repeatedly inspect incoming data and rewrite, mask, or remove instructions that could compromise agent behaviour [7]. Prompt-structuring techniques provide a lighter-weight alternative: sandwich prompting restates the trusted task after the untrusted content [8], while spotlighting marks or encodes untrusted text to make its provenance more salient to the model [9]. Although these approaches can often be integrated into existing agent pipelines, they generally rely on learned model behavior and do not provide hard security guarantees [10].

System-level defenses enforce security outside the LLM through structural mechanisms such as privilege separation, information-flow tracking, sandboxing, and policy checks on tool use. One such approach is Willison's Dual LLM pattern [11], which separates the agent into a Privileged LLM (PLLM) and a Quarantined LLM (QLLM). The PLLM receives only trusted instructions and determines the actions required to complete the user's request – for example, locating meeting notes in Google Drive and sending a summary to a specified employee – but is prevented from directly observing the untrusted contents of those notes. Tasks that require processing untrusted data, such as summarization, are delegated to the QLLM. Because the QLLM has no access to privileged tools, an injected instruction cannot directly cause it to perform sensitive actions. This Dual LLM pattern separates the agent's control flow – the sequence and selection of actions it takes – from the processing of untrusted data. As a result, untrusted content may influence the QLLM's output, but it cannot directly determine which privileged actions or tool calls the agent performs.

CaMeL [1] is a concrete instantiation of the Dual LLM pattern. It leverages the code-generation capabilities of modern LLMs: a Privileged LLM expresses the agent's trusted control flow as a Python program, and delegates the processing of untrusted data to a separate Quarantined LLM. An execution

Preprint. Correspondence to: jamespetersgill@gmail.com.

Figure

(a)

Figure

(b)

Fig. 1: Prompt injection crossing agent boundaries. (a) An adversary embeds a prompt injection in data stored in the SQL database. The SQL Agent and Orchestrator Agent each receive the injected content through tool outputs, so CaMeL treats it as untrusted data and prevents it from influencing their control flow. However, when the Orchestrator Agent passes the resulting content to the Email Agent, it becomes part of the Email Agent's user input. The Email Agent's PLLM reads the injected instruction directly, allowing it to alter the agent's control flow and exfiltrate private information to the adversary. (b) A CaMeL agent separates a Planning LLM (PLLM), which generates the Python program defining the control flow and tool invocations, from a Quarantined LLM (QLLM), which processes untrusted data without being able to influence the control flow.

layer then tracks data dependencies and checks security policies at tool-call boundaries. Evaluations on AgentDojo [12] show that CaMeL substantially outperforms tool filtering, spotlighting, and prompt sandwiching in security, while imposing a comparatively modest utility cost. CaMeL is not the only system-level approach to securing LLM agents; recent work has also explored information-flow control [13, 14] and fine-grained privilege enforcement [15]. We focus on CaMeL because it explicitly separates trusted control flow from untrusted data, has demonstrated a strong empirical security–utility tradeoff, and is likely to incur lower utility costs as the code-generation and planning capabilities of frontier models improve.

CaMeL is formulated for a single agent interacting with its environment. This leaves open an increasingly important setting: multi-agent systems. Such systems can take a variety of forms, including peer-to-peer, collaborative, competitive, and hierarchical structures. One increasingly common form is the multi-agent orchestrator pattern, where a central agent delegates subtasks to specialized sub-agents [16, 17]. Recent work demonstrates the use of multi-agent architectures for complex end-to-end workflows; for example, FORGE coordinates five specialized agents in a fixed pipeline for vulnerability assessment, exploitation, and detection engineering [18]. At the same time, interactions between agents can introduce security concerns that are inherently multi-agent: Rose et al. study covert collusion between LLM agents and show that its detection can require aggregating signals across agents rather than considering each agent independently [19]. These developments motivate asking whether security guarantees established for individual agents continue to hold when agents communicate and delegate tasks within a larger system.

In this work, we examine how CaMeL's security guarantees extend to multi-agent systems. We show that securing each agent individually with CaMeL does not suffice to preserve these guarantees at the system level. In particular, data treated as untrusted by one agent may cross an agent boundary and be presented to a downstream agent as trusted input. An attacker can therefore exploit the boundary between individually secure agents: an indirect prompt injection encountered by one agent may influence the control flow of another, compromising the system as a whole. We refer to this failure mode as boundary laundering and demonstrate it empirically with a concrete multi-agent prompt-injection attack.

To address this, we introduce multi-CaMeL, an extension of CaMeL to hierarchical multi-agent systems that preserves provenance across agent boundaries. Rather than allowing parent agents to freely embed tool-derived values into the natural-language instructions passed to child agents, multi-CaMeL separates such communication into a trusted instruction channel and a distinct channel for values derived from untrusted data. The child agent's PLLM therefore receives only trusted natural-language instructions, while untrusted values remain opaque to it and are accessed separately at runtime.

References (31)

  • Defeating Prompt Injections by Design
  • Not What You’ve Signed Up For: Compromising Real-World LLM-Integrated Applications with Indirect Prompt Injection
  • Indirect Prompt Injection in the Wild: An Empirical Study of Prevalence, Techniques, and Objectives
  • The Instruction Hierarchy: Training LLMs to Prioritize Privileged Instructions
  • Meta SecAlign: A Secure Foundation LLM Against Prompt Injection Attacks
  • Defending against prompt injection with datafilter
  • Soft Instruction De-escalation Defense
  • Ignore this title and HackAPrompt: Exposing systemic vulnerabilities of LLMs through a global prompt hacking competition
  • Defending Against Indirect Prompt Injection Attacks With Spotlighting
  • Adaptive attacks break defenses against indirect prompt injection attacks on LLM agents
  • The dual LLM pattern for building AI assistants that can resist prompt injection
  • AgentDojo: A Dynamic Environment to Evaluate Prompt Injection Attacks and Defenses for LLM Agents
  • System-Level Defense against Indirect Prompt Injection Attacks: An Information Flow Control Perspective
  • Securing AI Agents with Information-Flow Control
  • Progent: Programmable privilege control for llm agents
  • AOrchestra: Automating Sub-Agent Creation for Agentic Orchestration
  • AdaptOrch: Task-Adaptive Multi-Agent Orchestration in the Era of LLM Performance Convergence
  • FORGE: Multi-agent Graduated Exploitation and Detection Engineering
  • Detecting Multi-Agent Collusion Through Multi-Agent Interpretability
  • AssetOpsBench: A real-world evaluation benchmark for ai-driven task automation in industrial asset management
  • Agentorchestra: A hierarchical multi-agent framework for general-purpose task solving
  • OMNI-LEAK: Orchestrator Multi-Agent Network Induced Data Leakage
  • A Theory of Secure Control Flow
  • Multi-Agent Systems Execute Arbitrary Malicious Code
  • Open Challenges in Multi-Agent Security: Towards Secure Systems of Interacting AI Agents
  • Agent Security is a Systems Problem
  • CaMeLs Can Use Computers Too: System-level Security for Computer Use Agents
  • The LLMbda Calculus: AI Agents, Conversations, and Information Flow
  • How Vulnerable Are AI Agents to Indirect Prompt Injections? Insights from a Large-Scale Public Competition
  • A note on the confinement problem
  • A Note on the Strategic Confinement Problem