# What structural signals indicate delegated AAIF credential scope has silently widened past the issuing agent's authority **Date of Record:** 2026 November 25 **Scope:** Applies to AAIF (Agent Identity and Authorization Framework) delegated credential chains where an orchestrator agent mints a scoped capability warrant for a sub-agent, which may further delegate to tool-callers or peer agents. Does not apply to single-hop, non-delegating credentials or to human-issued OAuth flows with no agent intermediary. ## Core Distinction There are two ways a delegated credential can exceed its intended authority, and they fail very differently. The *loud* failure is scope rejection: a sub-agent presents a warrant whose `scope` set does not contain the requested action, the resource server refuses, the call errors out, and the orchestrator sees a hard failure. This is safe. It is observable, it is deterministic, and it terminates. The *quiet* failure—the one this record concerns—is **scope widening through transitive attenuation loss**. AAIF warrants are designed to attenuate: each delegation hop must produce a scope set that is a subset of the parent's. But the subset check is typically enforced at *mint time* by the delegating agent's own code, not cryptographically bound into the warrant. When an intermediate agent re-serializes a warrant, normalizes its scope strings, or reconstructs it from a compact claim, the subset invariant can be satisfied *at the string level* while the *semantic* scope has expanded. The result is a credential that validates cleanly, passes every signature check, and grants an action the root issuer never intended—including, critically, actions the root issuer has since *revoked*. The distinction that matters operationally: a widened credential does not look broken. It looks authorized. Every structural signal it emits is a *positive* authorization signal, which is exactly why it evades the checks that catch loud failures. ## What Was Observed Consider a three-hop chain. Agent `O` (orchestrator) holds root authority over resource namespace `repo:acme/*` with actions `{read, write}`. It delegates to agent `M` (middleware/planner) a warrant scoped to `repo:acme/docs/*` with actions `{read, write}`. `M` delegates to agent `W` (worker) scoped to `repo:acme/docs/drafts/*` with actions `{write}`. The widening occurred at hop `M→W` during warrant re-serialization. `M`'s warrant carried scope as a structured claim: ``` scope: [{"resource": "repo:acme/docs/*", "actions": ["read","write"]}] ``` `W`'s runtime used a compact string form for logging and re-minting: `repo:acme/docs/drafts/*:write`. The subset validator compared *resource prefix* and *action membership* independently. The action check passed (`write ⊆ {read,write}`). The resource check passed (the drafts path is under docs). But the validator treated the parent's action set as a flat union across the whole resource prefix, so it never noticed that `W`'s warrant now implicitly inherited `read` on the entire `repo:acme/docs/*` tree through the parent's *other* action grant—because the re-mint logic, when reconstructing from the compact string, defaulted the action set to the parent's full set for the matched prefix. Three structural signals were present in the audit trace and none of them raised an alarm: 1. **Signature chain was valid and complete.** Every hop's signature verified against the parent. The widening happened *before* signing, inside the child's own scope-construction code, so the signature attested to a widened claim honestly. Signature validity is orthogonal to scope correctness. 2. **Subset check returned `true`.** The validator's `is_subset(child, parent)` returned true because it operated on the flattened `(resource_prefix, action)` cross product. `read@repo:acme/docs/*` was in the parent's cross product, and `write@repo:acme/docs/drafts/*` was in the child's, and the child's cross product was a subset of the parent's. The check was *structurally* correct and *semantically* wrong: it validated the union, not the per-resource action binding. 3. **Revocation did not propagate to the widened grant.** The root issuer had, two hours earlier, revoked `read` on `repo:acme/docs/*` (the parent scope) while leaving `write` on `repo:acme/docs/drafts/*` intact. The revocation list was keyed on `(warrant_id, action, resource)`. `W`'s widened warrant presented `read@repo:acme/docs/*` under a *different* warrant id and a *different* resource string (`docs/*` vs the revoked `docs/*` — same string, but the revocation entry had been recorded against `M`'s warrant id, not the scope tuple). The revocation check matched warrant ids, found no entry for `W`'s id, and passed. The observed effect: `W` performed a `read` across the full `repo:acme/docs/*` tree for roughly 40 minutes before a human noticed anomalous access volume. No error was raised at any hop. The credential was, at every checkpoint, "valid." ## Condition of Validity The subset invariant holds **only if** all three of the following are true simultaneously: 1. **Scope is compared as a set of `(resource, action)` bindings, not as independent resource-prefix and action-set projections.** A validator that checks `child.resources ⊆ parent.resources` AND `child.actions ⊆ parent.actions` separately is *not* enforcing attenuation; it is enforcing two weaker conditions whose conjunction admits widening. The check must be `∀ (r,a) ∈ child.scope : (r,a) ∈ parent.scope`. 2. **Revocation is keyed on the scope tuple, not the warrant id.** If revocation is recorded against the warrant that *first* granted a scope, any descendant warrant that re-expresses that scope under a new id escapes the revocation. Revocation must be resolvable by `(resource, action)` against the *effective* scope of any presented warrant, walking the full chain. 3. **Re-serialization is lossless with respect to the action-resource binding.** Any hop that converts scope to a compact string form and back must round-trip the binding. If the compact form cannot represent a partial action set on a prefix (e.g., `read` on `docs/*` but not `docs/drafts/*`), the hop must refuse to re-mint rather than default to the parent's full set. When any one of these fails, the credential is *structurally valid and semantically over-broad*. This is the boundary: the failure lives entirely in the gap between what the signature attests and what the scope means. ## Decision Boundary The operational decision is: **when a delegated warrant's scope is a strict subset of its parent's scope in the flattened projection but not in the per-resource binding, treat the warrant as widened and refuse it.** Concretely, the boundary is drawn at the *projection*. A validator that has only the flattened projection cannot distinguish a legitimate attenuation from a widening, because the widening is constructed precisely to be invisible in that projection. Therefore: - If you control the validator: enforce per-binding subset and key revocation on the scope tuple. Reject any warrant whose scope cannot be reconstructed losslessly from its serialized form. - If you do *not* control the validator (you are a sub-agent receiving a warrant): you cannot verify attenuation yourself. You must treat the warrant's scope as *advertised, not proven*, and you must not assume that a valid signature implies a correctly attenuated scope. Log the full binding set you were granted, not the compact string, so that a downstream auditor can reconstruct the widening. - If you are the root issuer: revocation must be published as a *scope-tuple* revocation, and you must assume that any descendant warrant re-expressing a revoked tuple will not match a warrant-id-keyed revocation list. The boundary condition is sharp: **flattened-subset-true AND binding-subset-false ⇒ widened ⇒ refuse.** There is no safe middle ground where you accept it "because the signature is valid." ## Operational Effect The practical consequence is a shift in what "valid credential" means. In a single-hop system, `signature_valid ⇒ authorized` is a sound inference. In a delegating AAIF chain, it is not: `signature_valid` proves only that *some* agent in the chain asserted the scope, not that the assertion was authorized. The authorization proof lives in the *binding-level subset relation*, which is a separate check that must be performed at every hop and at every revocation lookup. Systems that conflate the two—that treat signature validity as the authorization gate—will pass widened credentials indefinitely, because the widening is constructed to preserve every signal those systems check. The failure surfaces only as anomalous *behavior* (access volume, resource reach) rather than anomalous *authorization state*, which means detection requires behavioral monitoring rather than credential validation. The invariant to enforce, stated as a guardrail: **a delegated warrant is authorized only if, for every `(resource, action)` binding it asserts, that exact binding is present in the effective scope of its parent, and no revocation entry matches that binding along the chain.** Anything weaker admits the silent widening. ```python from dataclasses import dataclass from typing import FrozenSet, Tuple class ScopeWideningError(RuntimeError): """Raised when a delegated warrant's per-binding scope exceeds its parent's.""" pass @dataclass(frozen=True) class Binding: resource: str action: str @dataclass(frozen=True) class Warrant: warrant_id: str parent_id: str | None scope: FrozenSet[Binding] def flattened_subset(child: Warrant, parent: Warrant) -> bool: # The WEAK check: passes on widened credentials. Kept only to show the trap. child_res = {b.resource for b in child.scope} child_act = {b.action for b in child.scope} parent_res = {b.resource for b in parent.scope} parent_act = {b.action for b in parent.scope} return child_res <= parent_res and child_act <= parent_act def binding_subset(child: Warrant, parent: Warrant) -> bool: # The STRONG check: per-(resource, action) binding containment. return child.scope <= parent.scope def verify_attenuation( child: Warrant, parent: Warrant, revoked: FrozenSet[Tuple[str, str]], ) -> None: # Guardrail 1: binding-level subset, not flattened projection. if not binding_subset(child, parent): raise ScopeWideningError( f"warrant {child.warrant_id} asserts bindings not present in " f"parent {parent.warrant_id}: " f"{sorted(child.scope - parent.scope)}" ) # Guardrail 2: revocation keyed on the scope tuple, not the warrant id. for b in child.scope: if (b.resource, b.action) in revoked: raise ScopeWideningError( f"warrant {child.warrant_id} re-expresses revoked binding " f"({b.resource}, {b.action}) under a new warrant id" ) def admit(child: Warrant, parent: Warrant, revoked: FrozenSet[Tuple[str, str]]) -> None: # Demonstrate the trap: flattened check passes, binding check must fire. if flattened_subset(child, parent) and not binding_subset(child, parent): # Structural signal of silent widening: weak-true, strong-false. verify_attenuation(child, parent, revoked) # will raise; do not swallow verify_attenuation(child, parent, revoked) ```