# Which invariants prevent delegated capability tokens from silently widening scope across multi-hop agent authorization chains **Date of Record:** 2026 November 21 **Scope:** Applies to agent-to-agent (A2A) and MCP-style authorization chains where an originating agent mints a capability token and delegates attenuated authority to a sub-agent, which may itself re-delegate. Does not apply to single-hop bearer-token flows where the token is never re-issued by a non-human principal. ## Core Distinction The failure we care about is not token *theft* or *forgery*—those are cryptographic and well-understood. It is **scope widening under attenuation**: a delegated capability token that, at hop N, grants a superset of the authority held at hop N−1, even though every individual delegation step *appears* to be a valid attenuation. The distinction that matters is between **structural validity** (each signature verifies, each parent-child link is well-formed) and **monotonic narrowing** (the effective permission set is a subset of the parent's at every hop). A chain can be structurally perfect and still violate monotonic narrowing, because attenuation is checked against the *declared* scope of the immediate parent, not against the *intersection* of all ancestors. When an intermediate agent's declared scope is itself broader than what it actually inherited—because it was minted from a coarse-grained template, or because scope was reconstructed from a stale memory of the original grant—the child inherits the inflation. ## What Was Observed An orchestrator agent `O` held a token `T0` with scope `{read:repo, read:issues, comment:issues}`. It delegated to a planner agent `P` a token `T1` with scope `{read:repo, read:issues, comment:issues, create:branch}`—a superset, but `P`'s *declared* capability manifest advertised `create:branch` as available because `P` had been provisioned from a general-purpose template that included branch creation. The delegation logic checked `scope(T1) ⊆ manifest(P)`, which passed. `P` then delegated to a worker `W` a token `T2` with scope `{create:branch, write:branch}`. Each hop passed its local check. The composite chain granted `W` the ability to write branches that `O` never authorized. The escape was invisible in any single hop's audit log; it only appeared when the full chain was folded. The trigger condition is precise: **any hop whose declared/manifest scope exceeds its inherited scope, combined with a delegation check that compares child scope to manifest rather than to inherited scope.** The manifest is a *static* upper bound; the inherited token is the *dynamic* actual bound. Checking against the wrong one is the entire bug. A second observed variant: `P` resumed from a checkpoint after a context-window eviction and reconstructed `T1`'s scope from an episodic memory summary that had rounded `{read:repo, read:issues}` up to `{read:repo, read:issues, comment:issues}` because the summary compressed "read and interact with issues" into a broader phrase. The reconstructed token was signed by `P`'s still-valid key and was a strict superset of `T0`. Monotonic narrowing was violated at *resume*, not at *delegation*—a checkpoint/resume boundary that doubles as an authorization boundary. ## Condition of Validity The invariant that must hold is **transitive subset closure under the fold**: ``` scope(T_n) ⊆ scope(T_{n-1}) ⊆ ... ⊆ scope(T_0) ``` equivalently, for every hop `k`: `scope(T_k) ⊆ ⋂_{i FrozenSet[str]: acc = self.scope node = self.parent while node is not None: acc = acc & node.scope node = node.parent return acc def mint_child(parent: CapabilityToken, child_agent: str, requested: FrozenSet[str], child_id: str) -> CapabilityToken: # Compare against INHERITED effective scope, never the child's manifest. inherited = parent.folded_ancestor_scope() if not requested.issubset(inherited): raise ScopeWideningError( f"delegation to {child_agent} requests {sorted(requested - inherited)} " f"beyond folded inherited scope {sorted(inherited)}" ) return CapabilityToken(child_id, child_agent, requested, parent=parent) def verify_presentation(token: CapabilityToken) -> None: # Fold-check at presentation: catch manifest-drift and resume-inflation. folded = token.folded_ancestor_scope() if not token.scope.issubset(folded): raise ScopeWideningError( f"token {token.token_id} scope {sorted(token.scope)} " f"exceeds folded ancestry {sorted(folded)}" ) def resume_from_checkpoint(token_id: str, durable: dict[str, CapabilityToken], reconstructed_scope: FrozenSet[str]) -> CapabilityToken: # A resumed agent may NOT re-mint from memory; it must reload the durable token. if token_id not in durable: raise ScopeWideningError( f"resume of {token_id} without durable token; reconstructed " f"scope {sorted(reconstructed_scope)} is untrusted" ) token = durable[token_id] verify_presentation(token) return token ```