cs.CRNov 8, 2026

On the Relative Security of Prompt Injection: Mechanised Definitions, Defences and Verdicts for LLM Agents

Authors: Brijesh Dongol

Organizations: University of Surrey, UK

Abstract

An LLM agent that reads untrusted content, such as an email or a web page, may follow instructions hidden in it. Noninterference is too strong for such agents, since a useful agent lets untrusted content influence what it does and may disclose the user's data by design, and declassification needs a release policy written for each task. We instead state security relative to a reference agent, which runs the same plan under the same runtime monitor with a model that never obeys untrusted content. An agent is relatively secure if every leak it has is a leak the reference already has. Our framework, PlanTERS, instantiates relative security, a notion from speculative execution, with a small agent language in which the attacker chooses how the model follows instructions, a composition with runtime monitors, and attacker models that differ in what they observe. A fence theorem shows that revoking injectable tools at the first untrusted read, and never granting them back, makes every plan relatively secure at the event level on finite runs, for every model behaviour in which each injection is a single call and the model obeys on a schedule fixed in advance; with a fairness condition, this extends to possibly infinite runs. We prove or refute relative security for agents with fences, budgets, approvals, loops and dual LLMs, in Isabelle/HOL.

Figures & tables

Appendix figures & tables1 asset

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. The Granularity Mismatch in Agent Security: Argument-Level Provenance Solves Enforcement and Isolates the LLM Reasoning Bottleneck

    May 11, 2026Linfeng Fan, Ziwei Li, Yuan Tian +3LLM Agent SecurityInformation Flow Control

  2. Toward Secure LLM Agents: Threat Surfaces, Attacks, Defenses, and Evaluation

    Jun 9, 2026Yuchen Ling, Shengcheng Yu, Zhenyu Chen +1Prompt InjectionLLM Agent Security