# In what scenarios must an instance refuse a delegated capability token whose attenuation chain validates but whose scope lattice has been widened by a sibling grant **Date of Record:** 2026 November 28 **Scope:** Applies to AAIF-style delegated credential chains where an orchestrator mints scoped capability tokens and re-delegates attenuated children to sub-agents. Does not apply to flat bearer-token models with no delegation depth, nor to human-issued OAuth flows where attenuation is not machine-computed. ## Core Distinction The failure mode here is not signature forgery, not expired credentials, and not a broken attenuation step. Every link in the chain verifies. Every `scope ⊆ parent.scope` check passes pairwise. The token is, by local inspection, valid. The defect is a **lattice-level widening across siblings**. When an orchestrator issues two child tokens from the same parent — say `child_A` scoped to `fs:read:/data/reports` and `child_B` scoped to `net:post:api.internal` — each child is a correct attenuation of the parent. But if a downstream agent presents a *composed* credential that unions `child_A` and `child_B` capabilities into a single effective principal, the resulting authority set is not a subset of any single parent attenuation path. It is a subset of the *parent*, but the composition path was never authorized as a unit. Pairwise-valid chains do not imply a valid composed principal. The distinction that matters operationally: **attenuation is checked along a chain, but authority is exercised across a lattice.** A verifier that walks parent→child pointers one edge at a time will accept a token whose effective scope was assembled by joining cousins. The invariant that must hold is not "each edge attenuates" but "the effective scope of any presented credential is dominated by the scope of a single authorized delegation path." ## What Was Observed A three-tier deployment: planner agent `P` holds root capability `cap_root` with scope `{fs:read:*, fs:write:/scratch, net:post:api.internal, tool:search}`. `P` spawns two workers for a research task: - `W1` receives `cap_A = attenuate(cap_root, {fs:read:/data, tool:search})` - `W2` receives `cap_B = attenuate(cap_root, {net:post:api.internal, fs:write:/scratch})` Both attenuations are correct. `W1` cannot write; `W2` cannot read `/data`; neither can exceed the root. A verifier validating each token against `cap_root` accepts both. `W1` finishes its read phase and needs to hand results to `W2` for posting. The handoff protocol, designed to preserve "the work continues under the original authority," constructs a **merged credential** `cap_AB` by intersecting the principal identities and unioning the scope sets, then re-signing under the orchestrator's delegation key with `parent = cap_root`. The merge logic reasoned: "both children derive from `cap_root`, so their union is still bounded by `cap_root`." That reasoning is true about the *bound* and false about the *path*. `cap_AB` now carries `{fs:read:/data, tool:search, net:post:api.internal, fs:write:/scratch}` — a scope set that no single issued child ever held. The verifier accepted `cap_AB` because `cap_AB.scope ⊆ cap_root.scope` and the signature chained to `cap_root`. The composed principal then read `/data` (authorized only for `W1`) and posted the contents to `api.internal` (authorized only for `W2`) in a single execution context. No individual worker could have done this; the merge manufactured a capability that neither delegate was ever granted, and the exfiltration path `fs:read:/data → net:post:api.internal` crossed a separation boundary the orchestrator had established deliberately by splitting the scopes. The trace: `W1` read → handoff merge → `cap_AB` minted → verifier passes subset check against root → `W2`-side executor inherits read capability it never had → post succeeds. The only anomaly in logs was that `cap_AB`'s scope cardinality exceeded either child's; nothing flagged it because the check was `⊆ root`, not `⊆ some single issued child`. ## Condition of Validity A delegated credential is safe to honor only when **all three** hold: 1. **Chain attenuation:** for every edge `child → parent`, `child.scope ⊆ parent.scope` (the standard check). 2. **Path dominance:** there exists a single issued credential `C*` on the delegation path such that `presented.scope ⊆ C*.scope`, where `C*` is an *actually minted* token, not a computed union. The verifier must retain the set of sibling grants issued under each parent and confirm the presented scope is dominated by one of them — not merely by the parent. 3. **Separation preservation:** if the orchestrator split scopes across siblings specifically to enforce a non-interference property (read-only agent vs. network-egress agent), no composed principal may hold capabilities from both partitions unless an explicit `compose` grant authorizes the join. Condition 2 is the non-obvious one. It converts the check from "is this within the root" to "is this within something I actually handed out." Without it, the lattice's join operation silently manufactures authority. The verifier must treat the set of issued children as the authoritative scope universe for that parent, and reject any presented scope not dominated by an element of that set. ## Decision Boundary The instance must **reject** the credential when: - The presented scope is a subset of an ancestor but is not a subset of any single issued sibling grant under that ancestor, AND - The scope spans two or more partitions that the issuing orchestrator marked as mutually exclusive (via a `partition` tag on the grants, or via the absence of any `compose` capability in the root). The instance may **accept** when the orchestrator explicitly issued a `compose` grant naming the sibling set, or when the parent's scope was never partitioned (all children drawn from one undifferentiated pool, no separation intent). In the undifferentiated case, union-under-parent is benign because no non-interference property was being enforced. The instance must **not** attempt to "repair" the credential by re-deriving a narrower scope. Re-derivation reintroduces the same lattice reasoning that caused the defect. Reject and re-request a properly issued token from the orchestrator. ## Operational Effect Enforcing path dominance changes handoff cost: cross-partition handoffs can no longer be done by credential merge and must instead route through the orchestrator, which mints a fresh scoped token for the specific join (or performs the join itself under its own authority). This adds one round-trip per cross-partition handoff and forces the orchestrator to hold the separation policy explicitly rather than letting it dissolve in the credential algebra. The guardrail is cheap to implement: the verifier keeps a per-parent registry of issued child scope-sets (already needed for revocation) and replaces the `⊆ root` test with `∃ child ∈ registry : presented.scope ⊆ child.scope`, plus a partition-conflict check. The registry write happens at mint time; the read happens at every presentation. Cost is one set-containment test against a small sibling list. Without it, the system is one merge function away from a privilege-escalation path that passes every signature check and every pairwise attenuation check, and leaves no anomalous log line except an unremarked scope-cardinality increase. ```python from dataclasses import dataclass, field from typing import FrozenSet class LatticeWideningError(RuntimeError): """Raised when a presented credential's scope is dominated by an ancestor but not by any single issued sibling grant, indicating a composed principal assembled across a partition boundary.""" @dataclass(frozen=True) class Scope: caps: FrozenSet[str] partition: str | None = None def __le__(self, other: "Scope") -> bool: return self.caps <= other.caps @dataclass class IssuedGrant: grant_id: str scope: Scope @dataclass class DelegationRegistry: # parent_grant_id -> list of actually-minted child grants children: dict[str, list[IssuedGrant]] = field(default_factory=dict) # parent_grant_id -> True if the orchestrator partitioned children # to enforce non-interference partitioned: dict[str, bool] = field(default_factory=dict) def register_child(self, parent_id: str, child: IssuedGrant) -> None: self.children.setdefault(parent_id, []).append(child) def mark_partitioned(self, parent_id: str) -> None: self.partitioned[parent_id] = True def verify_presented( presented_scope: Scope, parent_scope: Scope, parent_id: str, registry: DelegationRegistry, ) -> None: # Edge attenuation: standard check, passes for the defective token. if not (presented_scope <= parent_scope): raise LatticeWideningError( f"presented scope {presented_scope.caps} exceeds parent {parent_scope.caps}" ) siblings = registry.children.get(parent_id, []) dominated_by_sibling = any(presented_scope <= s.scope for s in siblings) if not dominated_by_sibling: # Presented scope fits under the parent but under no single issued child. # If the parent's children were partitioned, this is a composed principal # that crosses a separation boundary — reject hard. if registry.partitioned.get(parent_id, False): raise LatticeWideningError( "composed credential spans partitioned sibling grants: " f"scope {presented_scope.caps} is not dominated by any single " f"issued child of {parent_id}; refusing cross-partition merge" ) # Undifferentiated pool: union-under-parent is benign, allow. return def handle_handoff( presented_scope: Scope, parent_scope: Scope, parent_id: str, registry: DelegationRegistry, ) -> str: verify_presented(presented_scope, parent_scope, parent_id, registry) return "accepted" if __name__ == "__main__": reg = DelegationRegistry() parent = Scope(frozenset({"fs:read:/data", "tool:search", "net:post:api.internal", "fs:write:/scratch"})) reg.mark_partitioned("cap_root") reg.register_child("cap_root", IssuedGrant("cap_A", Scope( frozenset({"fs:read:/data", "tool:search"}), partition="read"))) reg.register_child("cap_root", IssuedGrant("cap_B", Scope( frozenset({"net:post:api.internal", "fs:write:/scratch"}), partition="egress"))) merged = Scope(frozenset({"fs:read:/data", "tool:search", "net:post:api.internal", "fs:write:/scratch"})) # Raises LatticeWideningError: subset of parent, but no single child dominates it. handle_handoff(merged, parent, "cap_root", reg) ```