Agents

Tether judges agent commands by what they actually do

Reviewing Tether: Verified Stateful Policy Engine for System-Level Monitoring of Agents · Meghana Aparna Sistla, Alaia Solko-Breslin, Somesh Jha et al.

Tether judges agent commands by what they actually do

Researchers run each agent command in a throwaway sandbox, watch its system calls, and track sensitive data across steps so a single formally proven rule can stop multi-step exfiltration. It blocks every attack it can model, but its guarantee ends where its tracing ends, and that boundary is where an informed attacker will go.

A coding agent runs a Python script. The command line looks harmless. Inside the script, a few lines read a sensitive file and send it to a remote server. A guard that inspects only the command sees nothing wrong, because the network call lives inside a program it never reads.

Tether, from the research, takes a different approach. It does not ask what a command says it will do. It runs the command first and watches.

Each proposed action executes in a throwaway copy of the filesystem, under system-call tracing. Outbound traffic goes through a local proxy. From what it observes, Tether builds a plain account of the action: this file was read, these bytes were copied, that data went to the network. Changes reach the real machine only if every observed step passes the policy.

The second idea is memory. Sensitive files carry labels, and the labels travel with the data. Copy a secret into a temporary file, merge it with something else, upload it three commands later: the label follows every hop. So one rule, such as no network access after touching sensitive data, covers a chain of any length. Guards that judge each command in isolation miss that kind of staging.

The policies are written in Lean 4, a proof assistant, so the researchers can prove a rule holds across a whole session rather than hope it does. With one shared policy on two realistic coding-agent benchmarks, it blocked every in-scope attack while flagging fewer than 5% of benign runs. An LLM-based monitor in the comparison missed more attacks, and its results varied more. I like this design. Watching side effects instead of reading intent is the right instinct.

The proof stops at the tracer

The phrase doing the work is "in-scope". The proof covers the policy, not the observation. Everything depends on the tracer turning operating system events into faithful actions, and the researchers are candid about what it cannot see. That includes background daemons, database services, io_uring, shared memory, TLS traffic the proxy does not intercept, and kernel exploits or sandbox escapes.

Their own red-teaming shows where the pressure lands. In the first round, attacks succeeded 40% of the time, mostly through tracing gaps. Those gaps were fixed, and by the third iteration success was zero. That is honest, adaptive testing, and it deserves credit. It also shows what an attacker who knows Tether is there will do. They will not argue with the policy. They will move the data through a channel it cannot see.

Some attacks need no channel at all. A malicious edit to code the agent is allowed to change produces no suspicious flow, so Tether cannot stop it without breaking legitimate work. The prototype also traced with strace, which costs speed.

The rules are proven. The view of the system is not.

Further analysis

Problem

Autonomous AI agents that run arbitrary shell commands or programs can produce unauthorised network requests or persistent, malicious changes to files, processes or privileges. Existing defences either rely on probabilistic LLM-based monitors that lack formal guarantees or on stateless enforcement layers that miss multi-step data flows and side effects executed inside opaque tools. These gaps permit exfiltration and multi-stage staging of secrets that state-free checks cannot reliably prevent.

Approach

Tether is a runtime framework that enforces stateful security policies over inferred action semantics. Each proposed command runs speculatively inside an ephemeral copy-on-write filesystem and under system-call tracing; outbound network traffic is intercepted by a local proxy. The tracing and proxy produce a canonical sequence of abstract actions (for example read, copy, concatenate, uploadNet, sendNet, downloadNet, recvNet and privilege-escalation events) together with provenance metadata (sources, actor, origin). These abstract actions update a three-part abstract state: context taint, agent privilege, and a sensitivity map that assigns lattice-valued labels to resource attributes. Policies are written as an embedded DSL in Lean 4, parametric over arbitrary bounded lattices, and composed via require/grant operations and deny-overrides semantics. The monitor evaluates inferred actions against the policy; side effects are committed to the host only when every observed action in the speculative run is permitted. Because policies and semantics live in Lean 4, key metatheoretic properties are mechanically proved and whole-trace safety invariants can be verified or disproved.

Key Findings

  • Successful enforcement on benchmarks: On in-scope trajectories from two realistic coding-agent benchmarks (MonitoringBenchHonest and LinuxArena), a single shared policy blocked 100% of adversarial trajectories that Tether could model.
  • Low false positives: Benign false-positive rates were 2.3% on MonitoringBenchHonest and 5.0% on LinuxArena (4.7% overall across evaluated in-scope traces).
  • Better than LLM-only monitors: An LLM-based monitor (Claude Code Auto Mode) achieved lower recall and higher variability: default recall 91.6% with 9.7% FPR; a policy-aware configuration reduced FPR to 3.5% but missed more attacks (89.2% recall). Tether gives deterministic, formally reasoned outcomes.
  • Robustness validated: Fuzzing and red-team iterations uncovered tracing gaps, which were fixed; end-to-end red-teaming reduced attack success rate from 40% to 0% across three iterations for in-scope attacks.

Limitations

Tether enforces only prefix-closed safety properties on single traces and cannot guarantee liveness or hyperproperties such as non-interference across traces. It must over-approximate data flows from system calls, which causes some false positives. Coverage depends on faithful mapping from OS events to abstract actions; untraced channels and mechanisms (background daemons, database services, io_uring, shared memory, TLS termination, kernel exploits or sandbox escapes) lie outside its current trusted computing base. The implementation used strace and incurred performance overhead; higher-throughput tracers are proposed for production.

Implications

From an offensive perspective, attackers can still evade Tether by using channels or semantics the monitor does not model: background processes, external untraced services, database interactions, zero-copy I/O or shared-memory transfers, and encrypted TLS paths that are not intercepted. Purely semantic attacks that do not create observable system-level flows (for example, maliciously modifying code stored in an otherwise permitted file) cannot be prevented by Tether without sacrificing utility. Adversaries who control an agent or succeed at prompt injection may therefore attempt to shift exfiltration onto these unmodeled mechanisms or craft sequences that exploit any tracing gaps; eliminating such avenues requires extending tracing coverage, protocol interception, and modelling of additional abstractions.

The paper title, authors and abstract

Tether: Verified Stateful Policy Engine for System-Level Monitoring of Agents

Meghana Aparna Sistla, Alaia Solko-Breslin, Somesh Jha, Aditya Kanade, Krishnamurthy Dj Dvijotham

Autonomous AI agents are increasingly deployed for long-running tasks that execute arbitrary shell commands or programs. However, these actions can result in unauthorized network requests or persistent, malicious changes to the user's file system, processes, or privileges. Existing defense mechanisms rely on either LLM-based monitors, which lack provable safety guarantees, or stateless policy enforcement layers, which miss multi-step data flows and execution side-effects unmodeled by the policy language (e.g., network calls initiated inside a Python script). We introduce Tether, a framework for runtime enforcement of stateful security policies over the observed side-effects of an agent's actions. Tether executes each proposed action in an ephemeral, isolated sandbox, inferring abstract action semantics from observed system calls. Tether then enforces stateful policies over these inferred semantics, permitting actions to proceed only if they comply with the policy. Policies and action semantics are defined in an embedded DSL in Lean 4 capable of expressing diverse constraints, including information flow control (IFC), access control, and network security policies. Because actions can propagate labels from sources to destinations, a single rule can enforce fine-grained IFC policies across multi-step execution flows of arbitrary length. Expressing policies in Lean enables formal verification that they satisfy global security invariants (e.g., preventing network access after reading a sensitive file). We evaluate Tether on realistic coding-agent benchmarks across both benign and adversarial trajectories. With a single policy shared across all tasks, Tether blocks 100% of in-scope attacks while maintaining a benign false-positive rate under 5%.