Manuscript Offprint

arXiv:2610.02569

Pincer: Resource Authorization for Agents using a Digital Twin

Mayank Rathee, Alexander Stepanov, Shalin Madabhavi, Jinhao Zhu, Raluca Ada Popa, Ion Stoica

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

Abstract

Coding agents have become increasingly long-horizon, autonomous, reliant on general-purpose shell and maintain their own persistent memory for self-improvement. While these capabilities have made the agents powerful, they have also made them harder to defend against external adversaries. Defenses that restrict this architecture—typed tools, information-flow control, or policy prediction engines—give up too much functionality to be adopted. Agents deployed today (e.g. Claude, Codex) rely on a combination of user-mediated and automode sandboxing as their primary defense. In user-mediated sandboxing, user-maintained policies decay over time and repeated permission requests cause user fatigue, while auto mode’s tool-call classifiers learn no user-specific policy and are not meant to defend against adversarial setups.

Pincer is a new defense that operates at the resource layer and works alongside existing defenses at the tool-call layer like the auto mode. At the core of Pincer lies a digital twin, an isolated-context model that automatically learns and enforces dynamic user-specific least-privilege policies. The digital twin keeps continually learning the user's preferences allowing it to act as the user's proxy for the agent's permission requests.

To emulate the learning phase, we propose a new user-centric dataset with examples following a multi-day transcript of user-agent interaction. Our evaluation shows that Pincer performs strongly on both security and utility in comparison to several baselines which includes variants of LLM judges and adaptations of Conseca (HotOS '25). We highlight attack types where Pincer's design leads to a significant security improvement compared to all other baselines, while outperforming the baselines even for other types of attacks.

1 Introduction

Coding agents [3, 40, 42, 43] have become increasingly autonomous, memory-driven, and reliant on general purpose computer-use tools like shell. These capabilities have ushered in a new era of computing with powerful automation, while also opening the door for vulnerabilities and attackers [5, 24, 27, 41, 55]. Researchers in both academia and industry have been looking for ways to make agents safer while balancing their usefulness.

In academia, there has been a major push towards strong defenses that in turn heavily restrict the agent's capabilities [13, 14, 21, 32, 48, 53, 56]. On the other hand, the focus in industry has been towards defenses that work well for most day-to-day use and preserving the functionality of agents as much as possible [3, 4, 29, 40, 42]. Sandboxed execution with policies over the agent's privileges, user-mediated permissions, and tool-call classifiers define these defenses. However, their effectiveness tends to decay over time (privilege creep and permission fatigue) and deviation from production traffic, e.g. when an adversary wants to take over the agent, can cause further failures [30]. In this work, we focus primarily on deployed agents and their existing defenses.

We present a new defense that plugs directly into today's agents and targets the resource layer that sits behind tools; for example files, web, etc. Central to our design is an entity we call the digital twin that learns user behavior over time to automatically infer which resources should be accessible to the agent for any given task. It additionally provides defense-in-depth by staying compatible with existing defenses that are already deployed. We call the system that composes an off-the-shelf agent with our defense Pincer 1^{1}. Our contributions are as follows:

  1. Pincer, an agentic system that learns user behavior and automatically authorizes resources for the agent on a per task basis.

  2. A user-centric synthetic dataset containing a coherent set of examples from different users' interaction with their agents over several days. The examples contain both attacks and benign workflows. To the best of our knowledge, it is the first dataset of this kind.

1^{1}Since pincers offer finer control than claws, we use Pincer as our system name to differentiate from less safe agents like OpenClaw.

  1. Implementation and evaluation of Pincer on top of a lightweight off-the-shelf agent NanoClaw [40].

References (62)