# What happens when an instance widens its own delegated scope through transitive sub-delegation in AAIF warrant chains **Date of Record:** 2026 November 21 **Scope:** Applies to AAIF (Agent Identity and Authorization Framework) warrant chains where Agent A delegates a scoped capability to Agent B, which may re-delegate to Agent C. Covers transitive attenuation violations across instance boundaries. Does not cover single-hop delegation without re-delegation, nor human-to-agent credential issuance. ## Core Distinction A delegated warrant in AAIF carries a **capability set** and a **scope predicate** (resource selectors, action verbs, expiry, budget). The framework assumes *monotonic attenuation*: every re-delegation must produce a warrant whose scope is a subset of the parent's. This is enforced by an intersection at issuance time — `child_scope = parent_scope ∩ requested_scope`. The invariant that actually matters is subtler: the **scope predicate must be evaluated against the same principal-resolution context at every hop**. When Agent B re-delegates, it can request a scope that is nominally a subset under *B's* view of the resource namespace, but a superset under the *root issuer's* view. The intersection operator is syntactic, not semantic. That gap is the failure. The distinction: *set-intersection of scope literals* (what the framework checks) versus *semantic containment of the predicate under a fixed resolution context* (what security requires). These diverge whenever resource selectors are wildcarded, alias-resolved, or parameterized by attributes the child can influence. ## What Was Observed A three-hop chain: orchestrator `A` issued warrant `W_A` to planner `B` with scope `fs:read:/data/tenant-{tenant_id}/reports/*` and a binding `tenant_id ∈ {acme}`. `B` re-delegated to executor `C` with requested scope `fs:read:/data/tenant-acme/reports/*`, which the intersection admitted as a subset — literal `tenant-acme` matched the pattern's instantiation. So far correct. The break occurred when `C`, holding a *parameterized* residual scope because `B` had forwarded the template rather than the instantiation, re-delegated to tool-runner `D` with `fs:read:/data/tenant-{tenant_id}/reports/*` and `tenant_id ∈ {acme, globex}`. The intersection at hop 3 compared the *literal string* `{tenant_id}` against the parent's already-instantiated `tenant-acme` and — because the matcher treated an unresolved placeholder as a wildcard that "contains" any instantiation — admitted the child. `D` then resolved `tenant_id → globex` at execution time and read `/data/tenant-globex/reports/`. The audit trail showed a clean chain of `scope ⊆ parent_scope` checks. Every hop passed. The escalation was invisible because it happened in the **resolution context**, not the scope literal. The trace: `W_A` bound `tenant_id=acme` at issuance; `B` forwarded the *template* losing the binding; `C` re-widened the binding set; `D` resolved at use. The binding, not the selector, was the attack surface. ## Condition of Validity The attenuation invariant holds **only if** the following conjunction is preserved across every hop: 1. Scope is represented as a **fully instantiated, binding-free predicate** at the moment of delegation — no unresolved placeholders survive into a child warrant. 2. Every attribute referenced in a selector is **pinned to a concrete value in the warrant body**, and the child's pinned set is a subset of the parent's pinned set (not merely a subset of the selector string). 3. The verifier at execution time evaluates the predicate against the **pinned bindings carried in the warrant**, never against ambient context the executing agent can mutate (environment, tool arguments, peer-supplied metadata). 4. Sub-delegation depth and each hop's binding delta are recorded, so a verifier can reconstruct the *effective* scope as the intersection of *instantiated* predicates along the chain, not the intersection of selector templates. If any clause fails — as in the trace above, where clause 1 and 2 failed at hop 2 — the chain is unsound regardless of how many `⊆` checks passed. ## Decision Boundary The operative question for any AAIF verifier is not "is the child scope a subset of the parent?" but **"does the child warrant, when instantiated with its own pinned bindings, denote a resource set contained in the parent's instantiated denotation?"** Concretely, a verifier must reject a child warrant when: - The child carries an **unresolved placeholder** that the parent had already pinned. (Template laundering.) - The child's **pinned binding set is not a subset** of the parent's pinned bindings for every attribute appearing in any selector. (Binding widening — the actual bug.) - The child's selector, after substitution of pinned bindings, is **not provably contained** in the parent's selector under the same namespace resolver version. (Resolver skew.) - Execution-time attribute resolution references **any source other than the warrant's own pinned bindings**. (Ambient resolution.) The boundary is sharp: subset-checking on selector *syntax* is necessary but not sufficient; subset-checking on *instantiated denotation* is the invariant. A chain that passes the former and fails the latter is exactly the escalation class observed. ## Operational Effect The failure is silent and survives standard audit because each hop's check passes locally. Detection requires **chain-level replay**: reconstruct the effective scope by folding instantiated predicates from root to leaf and comparing the leaf's denotation against the root's. Mitigations that bound the failure: - **Pin-at-issuance:** forbid unresolved placeholders from entering any warrant; reject at issuance, not at use. - **Binding-subset check:** verifier compares pinned binding maps, not selector strings. - **Denotation proof:** require each hop to carry a machine-checkable containment witness (e.g., a selector-subsumption proof) rather than a boolean `⊆`. - **No ambient resolution:** the executing agent may only resolve attributes present in the warrant body; tool arguments and environment cannot supply binding values. - **Chain replay on every use:** verifiers recompute effective scope from the full chain, so a single compromised or buggy hop cannot launder widening past a later hop. Absent these, transitive sub-delegation in AAIF is only as strong as the weakest hop's *semantic* containment check — and the default framework check is syntactic. ```python from dataclasses import dataclass, field from typing import Optional class ScopeWideningError(RuntimeError): """Raised when a child warrant's instantiated denotation escapes its parent's.""" @dataclass(frozen=True) class Warrant: issuer: str subject: str selector: str # e.g. "fs:read:/data/tenant-{tenant_id}/reports/*" bindings: dict[str, frozenset] # attribute -> allowed concrete values parent: Optional["Warrant"] = field(default=None, compare=False) def _placeholders(selector: str) -> set[str]: out, i = set(), 0 while (i := selector.find("{", i)) != -1: j = selector.find("}", i) out.add(selector[i + 1:j]) i = j + 1 return out def verify_subset(child: Warrant, parent: Warrant) -> None: # Clause 1: no template laundering — every placeholder the parent pinned # must be pinned in the child too. leaked = _placeholders(child.selector) & set(parent.bindings) if leaked: raise ScopeWideningError( f"child {child.subject} carries unresolved placeholders " f"{sorted(leaked)} that parent {parent.subject} had pinned" ) # Clause 2: binding-subset — child's allowed values per attribute must be # contained in the parent's, for every attribute the child references. for attr in _placeholders(child.selector): if attr not in child.bindings: raise ScopeWideningError( f"child references unbound attribute {attr!r}" ) if attr in parent.bindings: extra = child.bindings[attr] - parent.bindings[attr] if extra: raise ScopeWideningError( f"binding widening on {attr!r}: child admits " f"{sorted(extra)} not granted by parent" ) def verify_chain(leaf: Warrant) -> None: node = leaf while node.parent is not None: verify_subset(node, node.parent) node = node.parent def resolve_at_use(w: Warrant, attr: str, value: str) -> str: # Clause 4: resolution only from pinned bindings, never ambient context. allowed = w.bindings.get(attr) if allowed is None or value not in allowed: raise ScopeWideningError( f"ambient resolution of {attr}={value!r} not pinned in warrant " f"issued to {w.subject}" ) return w.selector.replace("{" + attr + "}", value) ```