When must an instance re-attest its AAIF scope after a silent permission downgrade?
**Date of Record:** 2026 December 2 **Scope:** Applies to multi-agent systems where an agent's runtime capabilities are governed by signed Agent-to-Agent Identity Framework (AAIF) scope tokens that can be downgraded mid-session by a policy authority. Does not cover static, session-long capability grants or human-issued OAuth flows without delegated attenuation.
Core Distinction
The failure here is not "the agent lacked permission." It is that the agent *believed* it still held a permission that had been silently revoked at the authority, and continued to plan and dispatch tool calls on the strength of a cached scope assertion. AAIF scopes are **attenuable**: a parent scope can be narrowed by a downstream issuer (a delegating agent, a policy broker, or an emergency revocation service) without notifying the holder. The token the holder carries remains cryptographically valid and unexpired — it is simply no longer a subset of what the issuer now permits. This is the distinction that matters: **token validity is not scope currency.** Signature checks pass; authorization still fails at the resource, often far downstream and asynchronously, after the agent has already committed irreversible work.
The non-obvious part is the asymmetry of detection. A downgrade is observable in exactly two places: (1) the authority's scope ledger, which the agent does not poll, or (2) the resource server's rejection, which arrives *after* the agent has burned a tool call and possibly mutated external state. Between those two points the agent runs on a stale attestation with no signal. Reasoning loops amplify this: a planner that has cached "I hold `write:filesystem`" will generate a multi-step plan that assumes it, and the plan only discovers the revocation at step 4, after steps 1–3 have produced side effects that assumed the capability.
What Was Observed
A three-agent pipeline: an orchestrator (holds root scope), a worker (holds an attenuated `fs.read` + `fs.write` + `net.egress` scope delegated at session start), and an auditor (holds `fs.read` only). At T+40s the policy broker narrowed the worker's scope — dropping `net.egress` and demoting `fs.write` to `fs.write:/tmp/**` — in response to a risk score crossing a threshold. The broker updated its ledger but did not push a revocation event; the worker's token carried an `exp` 900s in the future and no `not_before` change.
The worker was mid-task, executing a distilled plan of the form: read source → transform → write to `/data/out/` → POST results to an external collector. Steps 1–2 succeeded (still in scope). Step 3's write to `/data/out/` failed at the resource server with `E_SCOPE_NARROWED`. The worker's retry logic — which classified the error as transient because the HTTP status was 403 wrapped in a 5xx-shaped envelope by an intermediate proxy — retried twice, then fell back to step 4. Step 4's `net.egress` call also failed, but the worker had already distilled "write succeeded to /data/out" into its episodic memory from a *prior* successful run and was now reasoning over a stale success record. The orchestrator, holding root scope, saw only that the worker stalled; it re-dispatched the same plan to a fresh worker instance, which inherited the same stale episodic memory via the shared memory store and repeated the failure.
The trace that made this diagnosable: the worker's own attestation check (`verify(token, authority_pubkey)`) returned `True` at every step, because the token was never invalidated. Only the resource server's scope-subset check against the *current* ledger failed. The agent had no mechanism to distinguish "valid token, current scope" from "valid token, attenuated scope."
Condition of Validity
The invariant that was violated: **an agent may treat a scope assertion as current only if the assertion's `iat` is within one authority-lease window of the last successful resource-side authorization, OR the agent has received an explicit scope-state confirmation from the authority within that window.** Absent either, the scope must be treated as *unknown*, not as *held*.
This bounds the failure precisely. A downgrade is only safely ignorable when the agent re-validates against the authority (not just the token) at a cadence tighter than the broker's revocation propagation latency. In the observed system, broker propagation was event-driven and best-effort (~seconds to minutes), while the worker's plan horizon was ~60s of tool calls. The plan horizon exceeded the propagation bound, so the worker was structurally guaranteed to run on stale scope for some fraction of its plan.
The condition is *not* satisfied by signature verification, `exp` checks, or audience checks — all of which the stale token passed. It is satisfied only by a **scope-subset probe against the live ledger** or a **lease with a max-staleness field** that the agent honors by refusing to plan past it.
Decision Boundary
The boundary is: **re-attest when the remaining plan's estimated wall-clock exceeds the scope lease's remaining validity minus propagation slack; otherwise proceed on the cached attestation.**
Concretely, the worker should have computed, before dispatching step 3: `plan_remaining_estimate = 45s`, `lease_remaining = 860s`, but `propagation_slack` was undeclared (treated as 0), so the check passed incorrectly. The correct rule sets `propagation_slack` to the broker's documented worst-case revocation latency (here, unbounded because it was event-driven — which itself is the defect). When propagation latency is unbounded, the only sound boundary is **re-attest before every irreversible side effect** (writes, egress, external mutations), not merely before the plan.
The decision also has a downgrade-direction asymmetry: *widening* a scope never needs re-attestation mid-plan (the cached token is a subset of the new grant and remains valid). *Narrowing* always does, and narrowing is exactly the case where the agent has no push signal. So the guard must be biased toward re-attestation on any irreversible step, accepting the latency cost, rather than optimizing for the common case of no change.
Operational Effect
The practical consequence is a mandatory **attestation checkpoint** at every irreversible boundary, plus a memory-hygiene rule: a scope-narrowing rejection must invalidate any episodic record that asserted the now-revoked capability succeeded, because downstream reasoning will otherwise treat a stale success as evidence of current capability. In the observed system, the shared memory store propagated the poisoned success record to the re-dispatched worker, converting a single-instance failure into a fleet-wide replay of the same stale plan.
The guardrail that bounds it: treat `E_SCOPE_NARROWED` (and any 403 whose body carries a scope-delta) as a **terminal, non-retryable, memory-invalidating** signal — never as transient — and require the agent to re-attest against the live ledger before any subsequent irreversible step. Retry logic that maps 403 to transient is the single highest-leverage defect in this class, because it converts a detectable downgrade into an undetected one by burning the one signal the agent gets.
import time
from dataclasses import dataclass, field
class StaleScopeAttestation(RuntimeError):
"""Raised when an agent attempts an irreversible action on a scope
assertion that has not been confirmed current within the lease window."""
pass
class ScopeNarrowedRejection(RuntimeError):
"""Resource-side rejection indicating the held token is no longer a
subset of the issuer's current grant. Terminal; never retryable."""
pass
@dataclass
class ScopeLease:
scope: frozenset
issued_at: float
max_staleness: float # seconds; 0 or None => must re-attest every step
last_confirmed_at: float = field(default_factory=time.time)
def is_current(self, now: float | None = None) -> bool:
now = now or time.time()
if self.max_staleness is None or self.max_staleness <= 0:
return False
return (now - self.last_confirmed_at) <= self.max_staleness
def guarded_irreversible_step(
lease: ScopeLease,
required: frozenset,
action,
*,
probe_ledger, # callable(scope) -> current_scope | raises ScopeNarrowedRejection
invalidate_memory, # callable(reason) -> None
):
# Invariant: irreversible side effects require a *current* attestation,
# not merely a valid token.
if not lease.is_current():
current = probe_ledger(lease.scope) # may raise ScopeNarrowedRejection
lease.scope = current
lease.last_confirmed_at = time.time()
if not required.issubset(lease.scope):
invalidate_memory(f"scope narrowed: missing {required - lease.scope}")
raise StaleScopeAttestation(
f"required {required} not subset of current {lease.scope}; "
f"refusing irreversible action"
)
try:
return action()
except ScopeNarrowedRejection as e:
# Terminal. Poison the episodic success record so re-dispatched
# instances do not replay the stale plan.
invalidate_memory(f"resource rejected scope: {e}")
raise StaleScopeAttestation(
"resource-side scope narrowing; re-attest before next step"
) from e