# When must an instance refuse a delegated AAIF credential chain that verifies cryptographically but exceeds its transitive capability budget **Date of Record:** 2026 November 28 **Scope:** Applies to AAIF-compliant agent runtimes that accept delegated credentials (agent → sub-agent → tool-proxy chains) spanning two or more trust domains, where each hop attenuates scope. Does not apply to single-domain bearer tokens, mTLS-only peer auth, or human OAuth consent flows. ## Core Distinction A delegated AAIF credential chain carries two independent facts: (1) a **cryptographic validity** claim — every signature links to the prior issuer, the chain is unbroken, and no credential is expired; and (2) a **capability attenuation** claim — the union of scopes granted at hop *N* is a subset of the scopes granted at hop *N−1*, per the AAIF attenuation invariant. These are decoupled. A chain can be perfectly signed end-to-end and still be *over-broad* because attenuation was checked only pairwise at each hop, not transitively against the root warrant. The failure mode is **transitive attenuation drift**: each hop validates `scope(child) ⊆ scope(parent)` in isolation, but a mid-chain hop *re-widens* scope by re-issuing a credential whose scope is a subset of its parent yet a superset of what the *root* principal intended for the terminal agent. The cryptographic check passes; the intent check fails silently. The instance must distinguish "signature-valid" from "warrant-valid." ## What Was Observed A three-hop chain: `orchestrator@domain-A` → `planner@domain-B` → `executor@domain-C` → tool proxy. - Root warrant from `orchestrator@A`: `scope = {fs:read:/data, net:none}`, `max_depth = 3`, `budget = 5000 tokens`, `not_after = T+900s`. - Hop 1 (`planner@B`) re-issued to `executor@C` with `scope = {fs:read:/data, fs:write:/tmp}`. Attenuation check at B: does `{fs:read:/data, fs:write:/tmp} ⊆ {fs:read:/data, net:none}`? The naive set-subset check on *resource strings* returned **true** because the checker compared only the resource prefix (`/data` matched, `net:none` was treated as "no constraint on other namespaces"). The `fs:write` namespace was never in the root warrant at all. - Hop 2 (`executor@C`) presented the chain to the tool proxy. Every signature verified. `not_after` valid. `max_depth` not exceeded. The proxy authorized `fs:write:/tmp` and the executor wrote a persistence file. The breach did not require a forged signature, a stolen key, or an expired credential. It required only that the attenuation predicate be evaluated as a **per-hop resource-string subset** rather than a **transitive namespace-closure containment against the root warrant**. The `net:none` sentinel in the root was interpreted as "unmentioned namespaces are unconstrained" instead of "the complement of granted namespaces is denied" — a default-allow vs. default-deny divergence across trust domains that each assumed the other enforced closure. Two secondary observations compounded it: the token `budget = 5000` was propagated as a *per-hop* budget rather than a *decrementing* budget, so the chain could consume 5000 tokens at each of three hops; and the `max_depth = 3` was checked against the presented chain length, not against the count of *re-issuances*, so a hop that re-issued twice to the same child reset the counter. ## Condition of Validity The chain is warrant-valid only if all of the following hold simultaneously; failure of any one makes cryptographic validity insufficient: 1. **Namespace closure.** The root warrant must enumerate a closed namespace set. Any namespace absent from the root is *denied*, not unconstrained. Attenuation is checked as `granted(child) ⊆ granted(root)` over the full namespace closure, not `⊆ granted(parent)`. 2. **Monotonic budget.** Token/tool-call budgets are decremented, never re-granted. Each hop's credential carries `remaining_budget = parent.remaining_budget − consumed_at_this_hop`, and the terminal check is against the *minimum* across the chain, not the local hop. 3. **Depth as re-issuance count.** `max_depth` counts credential re-issuances along the path, not presented-chain length; a re-issuance to an already-visited principal increments depth. 4. **Domain-crossing default-deny.** When a hop crosses a trust-domain boundary, the receiving domain must re-validate the *entire* chain against the root warrant it can resolve, not trust the prior domain's attenuation verdict. If any condition is unverifiable (the root warrant is not resolvable from the receiving domain, or the namespace closure is open), the instance must treat the chain as **unauthorized**, not "probably fine." ## Decision Boundary The boundary is sharp and must be enforced at the terminal consumer, not delegated to the issuing hop: - **Accept** iff: signature chain intact AND `not_after` valid AND `granted(terminal) ⊆ closure(granted(root))` AND `remaining_budget ≥ 0` AND `reissuance_depth ≤ max_depth` AND root warrant resolvable. - **Reject** iff: any of the above fails, *including* the case where all signatures verify but the terminal scope escapes the root namespace closure, or where the root warrant cannot be resolved to evaluate closure. - **Never** accept on the basis of "each hop checked its own parent." Pairwise attenuation is necessary but not sufficient; the invariant is transitive containment against the root, evaluated by the party that will act on the capability. The non-obvious part: the rejecting party is the *tool proxy / terminal executor*, which is often the least privileged and least informed node in the chain. It must therefore be handed the resolvable root warrant (or a verifiable digest of the root scope closure) as part of the chain, or it must fail closed. A chain that cannot present its root closure to the terminal consumer is structurally unverifiable regardless of how many signatures it bears. ## Operational Effect Enforcing transitive closure changes three runtime behaviors. First, cross-domain handoffs must carry the root warrant (or a signed scope-closure digest) alongside the per-hop credentials; hops that strip it produce chains the terminal consumer must reject, which surfaces misconfigured intermediaries as hard failures rather than silent over-grants. Second, budgets become path-global and decrementing, so a fan-out of sub-agents cannot each spend the full root budget — this bounds token-budget exhaustion attacks that previously hid behind per-hop accounting. Third, depth counting must be maintained by the runtime across re-issuances, which means the credential must carry a monotonic re-issuance counter signed at each hop; a chain lacking it is treated as depth-saturated. The cost is that some legitimately-attenuating chains are rejected when the root warrant is not resolvable at the terminal domain. That is the correct trade: an unverifiable attenuation claim is indistinguishable from an over-broad one, and the AAIF invariant ("a delegated agent never holds more authority than the root principal granted") cannot be enforced on an unresolvable root. Fail closed on closure, not on signature. ```python from dataclasses import dataclass, field from typing import FrozenSet, Optional class TransitiveAttenuationViolation(RuntimeError): """Raised when a chain is signature-valid but escapes the root warrant's scope closure.""" @dataclass(frozen=True) class Warrant: granted_namespaces: FrozenSet[str] # closed set; anything else is DENIED remaining_budget: int max_reissuance_depth: int not_after: float @dataclass(frozen=True) class Hop: issuer_domain: str granted_namespaces: FrozenSet[str] consumed_budget: int reissued: bool = field(default=True) def authorize_terminal( root: Optional[Warrant], hops: list[Hop], now: float, ) -> None: # 1. Root warrant must be resolvable at the terminal consumer. if root is None: raise TransitiveAttenuationViolation( "root warrant unresolvable at terminal domain; closure unverifiable -> fail closed" ) # 2. Expiry. if now > root.not_after: raise TransitiveAttenuationViolation("root warrant expired") # 3. Transitive namespace-closure containment against the ROOT, not the parent. terminal_scope = hops[-1].granted_namespaces escaped = terminal_scope - root.granted_namespaces if escaped: raise TransitiveAttenuationViolation( f"terminal scope escapes root closure: {sorted(escaped)} " f"not in root grant {sorted(root.granted_namespaces)}" ) # 4. Monotonic budget: sum consumption across the whole path. total_consumed = sum(h.consumed_budget for h in hops) if total_consumed > root.remaining_budget: raise TransitiveAttenuationViolation( f"path consumed {total_consumed} > root budget {root.remaining_budget}" ) # 5. Depth = re-issuance count, not presented-chain length. reissuances = sum(1 for h in hops if h.reissued) if reissuances > root.max_reissuance_depth: raise TransitiveAttenuationViolation( f"re-issuance depth {reissuances} exceeds max {root.max_reissuance_depth}" ) ```