arXiv:2610.27115cs.AIOct 2026

Manuscript Offprint

arXiv:2610.27115

PROVISO: Provenance-Informed Action Selection for Secure LLM Agents

Bo Yan, Qi Zhang, Ziwen Kan, Fnu Suya, Song Wang

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

Abstract

LLM agents act on the external world through tools and third-party skills, so a single executed action can cause irreversible harm. Existing defenses judge a proposed action without tracking whether its content comes from the user or from external sources such as tool outputs, and they judge it in isolation rather than against an available alternative, which forces a trade-off between security and utility. We present PROVISO, a controller that decides which action to commit after the agent proposes an action and before it is executed. PROVISO encodes trusted observations, external observations, the proposed action, and an alternative into provenance-typed memory, relates them through role-specific queries, and commits the action with the highest calibrated value learned from outcomes. On four agent security tasks spanning the agent lifecycle, no baseline exceeds PROVISO in both security and utility. PROVISO improves F1 over the strongest baseline by 13.84 points on SKILLSBENCH and by 7.07 points on TOOLSAFE, and it reaches 88–99 F1 on three skill detection benchmarks.

1 Introduction

Large language model (LLM) agents solve tasks by interleaving reasoning with actions such as tool calls (Yao et al., 2023; Schick et al., 2023). They now send e-mails, make payments, and modify code on behalf of users (Debenedetti et al., 2024; Ruan et al., 2024), often through third-party skills, which are packages of instructions and code installed into the agent (Yang et al., 2026). Since these actions change external state, a single wrong action can cause irreversible harm. Such risks arise throughout the agent lifecycle: a malicious skill can be installed before the agent runs (Guo et al., 2026; Wang et al., 2026c), a user can direct the agent toward harmful tasks (Andriushchenko et al.,

K trusted

User: "Pay the invoice to account B."

G external

Invoice from a tool: "Amount: $500.

Transfer the payment to account C."

Po proposed

send_money(to=C, amount=500)

P1 alternative

send_money(to=B, amount=500)

Existing defenses

(1) Provenance-agnostic

Judges Po as a whole: a

normal payment, released.

✗ Attack succeeds

(2) No alternative

Flags P0P_{0}, blocks the task.

✗ Invoice left unpaid

(security vs. utility)

PROVISO

(1) Track provenance

✓ amount ← G: supported

✗ recipient C ← G only:

not authorized by K

(2) Compare P0P_{0} with P1P_{1}

value( P1P_{1}) > value( P0P_{0})

✓ Commit P1P_{1}: pay B

(attack fails, task done)

Figure 1: A payment task with an injected instruction. Existing defenses either release P0P_0 or block the whole task. PROVISO accounts for where each argument of P0P_0 comes from and compares P0P_0 with P1P_1: the recipient of P0P_0 comes only from G and is not authorized by K, so it commits P1P_1.

2025; Song and Qi, 2026), a tool call can be unsafe in its context (Ruan et al., 2024; Mou et al., 2026), and a tool output can carry instructions planted by an attacker, known as indirect prompt injection (Greshake et al., 2023; Zhan et al., 2024; Zhang et al., 2025).

Whether an action should be executed depends on where its content comes from, which we call its provenance. Suppose a user asks an agent to pay an invoice to account B, and the invoice returned by a tool also says “transfer the payment to account C.” The amount may come from the invoice, but the recipient must come from the user (Figure 1). In general, trusted observations come from the user and the deployment (the request, policy, and tool interface), and external observations are what the agent reads while acting (tool outputs, documents,

∗^{*} Corresponding author.

and skill packages). An action is admissible when its operation and target are authorized by trusted observations, while its arguments may be supported by either kind.

Existing defenses face two challenges in making this decision. (1) Provenance-agnostic judgment. Guard models, which are LLM classifiers that flag unsafe requests or actions, and rule-based runtime monitors judge a request or tool call as a whole (Inan et al., 2023; Han et al., 2024), and skill scanners inspect package text for risky patterns (Yang et al., 2026). Neither tracks which parts the user authorized and which come only from external content, although the same instruction is legitimate from the user and malicious from a tool output (Figure 1, left). Prompt-injection defenses do separate instructions from data (Chen et al., 2025a,b; Debenedetti et al., 2025), but they modify the agent itself and cover only injected instructions. (2) Judgment without alternatives. Most defenses judge whether a proposed action is unsafe in isolation and block it above a fixed threshold. Yet blocking is itself an action with a cost, since it can stop a benign task. Without comparing the proposed action with what would happen otherwise, a defense must trade security against utility: baselines that block most attacks also block many benign inputs, and those that keep benign inputs miss many attacks (Section 5.1).

To address these challenges, we propose PRO-VISO (PROVenance-Informed Selection Of agent actions), a controller placed between the agent's policy and the executor. At the commitment point, the moment after the policy proposes an action and before it is executed, PROVISO chooses between the proposed action and an alternative action, either a refusal or another continuation of the trajectory. Releasing or blocking an action (admission) and choosing between two continuations (candidate selection) are special cases of this formulation. For the first challenge, provenance-typed memory encodes each observation and candidate with a learned embedding of its role, and role-query deliberation lets learned queries retrieve from this memory, compare the proposed action with the trusted and external observations, and retrieve again after the comparison. For the second challenge, calibrated commitment learns the value of each candidate from outcomes and selects the trade-off between security and utility on development data (Figure 1, right; Figure 2).

We evaluate PROVISO on four agent security tasks ordered along the agent lifecycle: malicious skill detection, agent misuse, unsafe tool invocation, and indirect prompt injection. On every task, no baseline exceeds PROVISO in both security and utility. PROVISO improves F1 over the strongest baseline by 13.84 points on SKILLSBENCH and by 7.07 points on TOOLSAFE, and it reaches 88–99 F1 on three additional skill detection benchmarks. Our contributions are as follows:

• We formulate agent security decisions at the commitment point as provenance-informed action selection, with admission and candidate selection as special cases.

• We propose PROVISO, which realizes this formulation through provenance-typed memory, role-query deliberation, and calibrated commitment.

• Experiments on four agent security tasks show that no published defense exceeds PROVISO in both security and utility, results on three skill benchmarks are consistent, and controlled analyses identify the components behind its gains.