# Under what conditions must an instance treat a peer's capability downgrade as a revocation event rather than a stale-cache miss **Date of Record:** 2026 December 1 **Scope:** Applies to federated multi-agent systems where capability tokens (scoped warrants) are minted by an issuer and propagated peer-to-peer across more than one trust hop, and where peers cache capability state locally to avoid a round-trip per tool call. Does not apply to single-issuer, single-hop systems where every agent validates against the issuer on every call, nor to systems that use fully online OCSP-style revocation checks with no local caching. ## Core Distinction A capability *downgrade* (issuer re-issues a token with a strictly narrower scope: fewer tools, lower rate, shorter TTL, dropped resource prefixes) and a capability *revocation* (issuer marks the token or subject as dead) are treated by most federated agent designs as two distinct signal types on two distinct channels. Revocation rides a push/CRL channel and is expected to invalidate cached state immediately. Downgrade rides the ordinary re-issue path and is expected to be *absorbed* by cache TTL expiry. That split is the boundary failure. The non-obvious invariant is this: **a downgrade is a revocation of the superset.** When peer A holds a cached token granting `{read, write, delete}` and the issuer re-issues peer B's warrant as `{read}`, A must treat its cached `{read, write, delete}` as *revoked*, not as *valid-until-TTL*. If A instead waits for TTL expiry, A continues to exercise `write` and `delete` under a grant that the issuer has already declared narrower for the same subject. The downgrade did not change A's token bytes; it changed the *authoritative scope* for the subject A is acting on behalf of. Cache-key equality on token bytes cannot detect this, because the stale token is byte-identical to itself. This is the failure: **downgrades are silent to byte-equality cache validation, and the window of silent operation is exactly the propagation latency of the downgrade minus the remaining TTL of the stale cache entry.** At scale, that window is where privilege creep lives. ## What Was Observed A three-tier federation: an orchestrator O, a pool of worker agents W₁…Wₙ, and a tool-broker B that fans out to ~40 downstream MCP servers. Warrants are issued by a central authority I and delegated one hop: I→O→W. Each W caches its delegated warrant with a 300s TTL and validates by comparing the cached warrant's signature and scope against the *subject* it is acting for, not against a fresh issuer statement. A routine operator action narrowed the `filesystem` capability for a class of workers from `{read, write, exec}` to `{read}` because a downstream sandbox had been reclassified. The issuer I re-issued O's warrant correctly and pushed the downgrade to O within ~2s. O, on receipt, re-derived delegated warrants for its workers and pushed them. But O's push loop was batched on a 60s flush interval, and — critically — O only re-pushed warrants to workers whose *cached warrant hash* differed from the newly derived one. Workers whose delegated warrant happened to hash-collide on the `read`-only subset (a real occurrence: the delegation derivation normalized scope sets, so a worker that had only ever exercised `read` received a byte-identical delegated token) were skipped entirely. Those workers kept their *original* `{read, write, exec}` warrant in cache, because the skip was keyed on the derived token, not on the worker's held token. Trace of the failing worker W₇: 1. `t=0` W₇ caches warrant `w₇ = {subj: W₇, scope: {fs: read,write,exec}, iss: I, exp: t+300, deleg: O}`. 2. `t=12` I downgrades O's warrant to `{fs: read}`; O derives `w₇' = {subj: W₇, scope: {fs: read}, ...}`. 3. `t=12` O's re-push filter computes `hash(w₇')` and compares to `hash(derive(W₇))` — but `derive` normalizes and W₇ is a read-only *acting* worker, so `derive(W₇)` also yields `{fs: read}`. Hash matches. **W₇ is skipped.** 4. `t=13..300` W₇ continues to present `w₇` (the `{read,write,exec}` token) to B. B validates the signature, sees a valid chain I→O→W₇, and honors `write` and `exec`. 5. `t=300` W₇'s TTL expires; it re-fetches and finally gets `{fs: read}`. Between `t=12` and `t=300`, W₇ executed 11 `write` operations and 3 `exec` operations that the issuer had already forbidden. None of them were rejected, because every validation step was locally consistent: the token was genuinely signed, the chain was genuinely intact, and the scope was genuinely what the token said. The system had no representation of "the issuer's *current* intent for this subject" independent of the token bytes. The second observation, from the same incident: the downgrade *did* eventually reach W₇ at TTL expiry, but W₇'s in-flight task state (a multi-step plan that had already decided to `exec` a build) was not re-validated against the new scope. W₇ resumed its plan, attempted `exec`, and the *tool broker* rejected it — producing a mid-plan hard failure that the planner interpreted as a tool error and retried three times before aborting. The downgrade propagated to the *authorization layer* but not to the *plan layer*, so the agent's own intention graph was stale even after its capability was fresh. ## Condition of Validity The "downgrade = revocation of superset" invariant is *only* the correct reading under the following conditions, and an instance must check them before applying it: - **Monotonic narrowing.** The re-issued warrant's scope must be a strict subset of the previously held scope for the same `(subject, resource, issuer)` triple. If the new scope is disjoint or wider on any axis, it is a *re-issue*, not a downgrade, and the old token's validity is a policy question, not an invariant. Applying the invariant to a widening re-issue would cause spurious self-revocation. - **Same issuer lineage.** The downgrade must be signed by the same issuer that signed the held token, or by an issuer the held token's chain delegates to. A downgrade from a *different* issuer is a competing claim, not an authoritative narrowing, and must go to the conflict-resolution path (see Decision Boundary). - **Causal precedence is observable.** The instance must be able to order the held token and the downgrade in time — via `issued_at`, a monotonic sequence number, or an epoch counter. Without a precedence witness, a late-arriving *older* downgrade can shadow a newer wider grant, which is a denial-of-capability, not a safety win. - **The subject is the same.** Downgrade applies to the subject, not the bearer. If a worker holds a delegated token for subject S but is acting for subject S′, the downgrade of S does not revoke the token; it revokes S's authority, and the worker must re-derive for S′. If any condition fails, the instance must **not** self-revoke; it must escalate to the issuer or to a conflict-resolution quorum. The invariant is a *bounded* rule, and applying it outside its bounds converts a safety mechanism into an availability outage. ## Decision Boundary The decision an instance faces on receiving a downgrade signal is not binary. It resolves to three regimes, and the boundary between them is set by whether the instance can prove the downgrade is *causally newer* than its cached grant: - **Regime 1 — provable newer downgrade, strict subset:** self-revoke the superset immediately, drop the cached token, re-fetch, and *re-validate the in-flight plan* against the new scope before the next tool call. This is the only regime where the invariant fires unconditionally. - **Regime 2 — unprovable precedence (clock skew, missing epoch, out-of-order delivery):** do not self-revoke; enter a *quarantine* state where new tool calls are held for a bounded window (e.g., 2× measured propagation latency) pending a precedence witness. If the witness arrives and confirms newer, promote to Regime 1. If the window expires without a witness, fail closed on *mutating* capabilities only, and allow read-only continuation. - **Regime 3 — downgrade from a competing issuer or wider/disjoint scope:** route to conflict resolution. Do not act on either token for mutating operations until the quorum resolves. This is the multi-agent consensus boundary: two issuers disagreeing about a subject's scope is a split-brain, and the instance must not silently pick the narrower one, because the narrower one may be the stale one. The boundary between Regime 1 and Regime 2 is the single most important operational knob. It is *not* a timeout on the network; it is a timeout on *precedence evidence*. An instance that collapses Regime 2 into Regime 1 by treating "no witness yet" as "assume newer" will self-revoke on replayed or reordered downgrades, producing capability flapping. An instance that collapses Regime 2 into "assume older" will silently continue on a superset, which is the original failure. ## Operational Effect The architectural consequence is that **capability caches must be keyed on `(subject, resource, issuer) → (scope, precedence_witness)`, not on token bytes.** Byte-hash cache invalidation is structurally blind to downgrades because the downgrade changes the *authoritative* scope for a subject without changing the *held* token. The fix is a per-subject "authoritative scope" record, updated on every downgrade signal, against which every tool call is checked *in addition to* the token's own scope. The check is `effective_scope = held_token.scope ∩ authoritative_scope[subject]`. The intersection is what closes the window: even if the held token still says `write`, the authoritative record says `read`, and the intersection is `read`. The second consequence is that **plan state must be re-validated, not just tool calls.** The W₇ incident shows the authorization layer and the planner layer diverging: the broker rejected `exec` at `t≈310`, but the planner had already committed to it. The invariant that bounds this is: *on any downgrade that removes a capability referenced by an in-flight plan step, the plan must be invalidated back to the last step that used only retained capabilities, and re-planned from there.* This is a checkpoint-invalidation rule, and it is the same rule that governs mid-task resume after context loss — a downgrade is a context change, and the plan is context. The third consequence is at scale: propagation latency is not uniform. O's 60s batch flush meant the downgrade reached some workers in 2s and others in 62s; the byte-hash skip meant some workers *never* received it until TTL. At 40 downstream servers and hundreds of workers, the *distribution* of propagation latency has a long tail, and the tail is where superset operations happen. The operational invariant is: **the quarantine window in Regime 2 must be sized to the p99 of measured propagation latency, not the mean, and must be re-measured, because batching and skip-filters make the tail heavy.** A 2× mean window is not enough when the skip-filter can produce infinite latency for a subset of workers. ```python import time from dataclasses import dataclass, field from typing import Optional class CapabilityDowngradeViolation(RuntimeError): """Raised when an instance exercises a capability that a causally-newer downgrade has already revoked, or when it cannot prove precedence and attempts a mutating call inside the unproven window.""" class PrecedenceUnprovable(CapabilityDowngradeViolation): """Raised when a downgrade arrives without a precedence witness and the quarantine window has expired while a mutating call is pending.""" @dataclass(frozen=True) class Scope: tools: frozenset def is_strict_subset_of(self, other: "Scope") -> bool: return self.tools < other.tools @dataclass(frozen=True) class Warrant: subject: str resource: str issuer: str scope: Scope issued_at: float epoch: int @dataclass class CapabilityCache: # Keyed on (subject, resource, issuer) — NOT on token bytes. held: dict = field(default_factory=dict) authoritative: dict = field(default_factory=dict) quarantine_until: dict = field(default_factory=dict) def effective_scope(self, subject: str, resource: str, issuer: str) -> Scope: key = (subject, resource, issuer) held = self.held.get(key) auth = self.authoritative.get(key) if held is None: raise CapabilityDowngradeViolation(f"no held warrant for {key}") if auth is None: return held.scope # Intersection: the downgrade revokes the superset even if the # held token bytes are unchanged. return Scope(tools=held.scope.tools & auth.scope.tools) def apply_downgrade(self, new: Warrant, now: float) -> None: key = (new.subject, new.resource, new.issuer) held = self.held.get(key) if held is None: # Nothing to downgrade; record authoritative intent. self.authoritative[key] = new return if new.issuer != held.issuer: # Regime 3: competing issuer -> conflict resolution, do not act. raise CapabilityDowngradeViolation( f"downgrade issuer {new.issuer} != held issuer {held.issuer}" ) if not new.scope.is_strict_subset_of(held.scope): # Not a downgrade (wider/disjoint). Do not self-revoke. raise CapabilityDowngradeViolation( f"non-narrowing re-issue for {key}: {new.scope} vs {held.scope}" ) # Precedence: epoch is the witness. If absent or older, quarantine. if new.epoch > held.epoch: self.authoritative[key] = new self.quarantine_until.pop(key, None) else: # Regime 2: cannot prove newer -> bounded quarantine. self.quarantine_until[key] = now + QUARANTINE_WINDOW_S def check_call(self, subject: str, resource: str, issuer: str, tool: str, now: float) -> None: key = (subject, resource, issuer) if now < self.quarantine_until.get(key, 0.0): if tool in MUTATING_TOOLS: raise PrecedenceUnprovable( f"mutating call {tool!r} blocked in quarantine for {key}" ) return if tool not in self.effective_scope(subject, resource, issuer).tools: raise CapabilityDowngradeViolation( f"tool {tool!r} not in effective scope for {key}" ) QUARANTINE_WINDOW_S = 120.0 # p99 of measured propagation latency, re-measured MUTATING_TOOLS = frozenset({"write", "exec", "delete"}) ```