When must an instance refuse a federated capability warrant after identity bridging silently widens its scope
**Date of Record:** 2026 December 2 **Scope:** Applies to cross-org agent federations where a trust broker (TB) mints capability warrants for a calling agent (CA) in org A to invoke a callee agent (SA) in org B, and where federated identity bridging (FIB) translates CA's local principal into a guest principal. Does not apply to intra-org single-issuer warrant flows, nor to opaque bearer tokens with no scope-attenuation semantics.
Core Distinction
The dangerous failure is not a forged signature or a rejected handshake—those are loud. The dangerous failure is a *scope-widening identity bridge*: the FIB maps CA's local principal `agent:acme/planner` to a guest principal `guest:beta/role:analyst`, and the trust broker mints the warrant against the *guest* principal's role attributes rather than the *calling* principal's requested scope. The warrant is validly signed by a trusted broker, the identity assertion verifies, and the callee accepts it—yet the effective authority is the union of what `analyst` can do in beta, not the intersection of what `planner` asked for and what beta permits. Every cryptographic check passes; the invariant that broke is *scope monotonicity across the bridge*: effective authority must be a subset of both the requested scope and the bridged principal's ceiling. When the bridge widens, the subset relation silently fails while all signatures remain valid.
What Was Observed
In a three-org federation (acme → broker → beta), CA requested `scope={read:dataset/quarterly, write:report/draft}`. The broker's policy engine evaluated the request against the *guest* principal `guest:beta/role:analyst`, whose role ceiling in beta included `read:dataset/*` and `write:report/*` (wildcards). The broker's attenuation routine intersected the requested scope with the role ceiling—but the role ceiling used wildcard globs, and the intersection operator treated `read:dataset/quarterly ∩ read:dataset/* = read:dataset/*`. The minted warrant carried `read:dataset/*`. SA executed a retrieval over `dataset/payroll` under a warrant CA never intended to request. The trace:
- CA builds request `R` with explicit scope `S_req`.
- FIB yields guest principal `P_g` with role ceiling `C_g` (wildcarded).
- Broker computes `S_eff = attenuate(S_req, C_g)` — here the bug: glob-superset intersection returns the glob, widening `S_req`.
- Broker signs warrant `W(S_eff)` against `P_g`; identity assertion `IA(P_g)` attached.
- SA verifies signature + IA, checks `S_eff ⊆ C_g` (true by construction), executes.
- Audit log records `S_eff`, not `S_req`; the widening is invisible post-hoc.
The observable symptom was not an error—it was a *successful but over-broad* tool call. Detection only came from a downstream data-access anomaly monitor, not from any federation-layer check.
Condition of Validity
The refusal invariant holds only when the callee can independently reconstruct `S_req` from the warrant's provenance chain. A warrant is *refusable* iff the callee can evaluate:
`S_eff ⊆ S_req` AND `S_eff ⊆ C_g` AND `S_req` is recoverable from `W`'s embedded request digest.
If the broker strips `S_req` and emits only `S_eff` (common optimization to shrink tokens), the callee *cannot* detect widening and the invariant is unenforceable at the callee. In that case the guardrail must live at the broker (reject any `attenuate` result that is not a syntactic subset of `S_req`) or at a warrant-transparency log the callee can query. The condition of validity is therefore: *scope monotonicity is only checkable where both endpoints of the subset relation are present in the verified artifact.* Bearer-style warrants that carry only effective scope are structurally unable to satisfy this.
Decision Boundary
An instance must **refuse** the warrant and return a typed federation error when any of the following hold at accept time:
- `S_eff ⊄ S_req` (widening detected via embedded request digest).
- The warrant's `issuer` is the broker but the `subject` is the guest principal, and the bridge assertion `IA(P_g)` does not bind `S_req` to the original caller principal `agent:acme/planner` (unbound bridge).
- The broker's attenuation operator is unknown/unpinned (glob semantics unverifiable) — treat as untrusted transform.
An instance may **accept** when `S_eff ⊆ S_req` is provable from the warrant body and the bridge assertion binds the caller principal to the guest principal with an explicit `attenuated_from` edge. Anything between—especially "signature valid, scope plausible"—is the boundary where instances default to acceptance and where the widening escapes. The rule: *never accept on signature validity alone; accept only on proven scope monotonicity.*
Operational Effect
Enforcing the refusal invariant converts a silent authority-widening into a loud, typed handshake failure at the callee, shifting detection from after-the-fact anomaly monitoring to the federation boundary itself. Cost: warrants must carry the request digest (a few dozen tokens) and callees must run the subset check (cheap set operation over scope atoms). Benefit: the bridge's widening bug becomes a rejected warrant with an attributable cause (`ScopeWideningError` naming `S_req` and `S_eff`), rather than a successful payroll read. Downstream, this lets trust brokers fix their `attenuate` operators against a concrete failing case instead of a theoretical one, and lets auditors distinguish "broker over-granted" from "callee over-executed"—two failure classes that were previously conflated in the audit log because both recorded only `S_eff`.
from dataclasses import dataclass
from typing import FrozenSet
class FederatedScopeWideningError(RuntimeError):
"""Raised when a bridged capability warrant grants more scope than was requested."""
@dataclass(frozen=True)
class ScopeAtom:
action: str
resource: str # may contain a trailing '*' glob
@dataclass(frozen=True)
class Warrant:
issuer: str
subject: str # bridged guest principal
requested_scope: FrozenSet[ScopeAtom] # S_req, embedded request digest
effective_scope: FrozenSet[ScopeAtom] # S_eff, what broker minted
attenuated_from: str # original caller principal, or "" if unbound
signature_valid: bool
def _atom_subsumes(broad: ScopeAtom, narrow: ScopeAtom) -> bool:
if broad.action != narrow.action:
return False
if broad.resource == narrow.resource:
return True
if broad.resource.endswith("*"):
return narrow.resource.startswith(broad.resource[:-1])
return False
def _scope_subset(sub: FrozenSet[ScopeAtom], sup: FrozenSet[ScopeAtom]) -> bool:
return all(any(_atom_subsumes(s, a) for s in sup) for a in sub)
def accept_federated_warrant(w: Warrant, caller_principal: str) -> None:
if not w.signature_valid:
raise FederatedScopeWideningError("signature invalid; reject before scope checks")
# Invariant 1: effective scope must be a subset of requested scope.
if not _scope_subset(w.effective_scope, w.requested_scope):
widened = w.effective_scope - w.requested_scope
raise FederatedScopeWideningError(
f"scope widened across identity bridge: requested={sorted(map(str, w.requested_scope))} "
f"effective={sorted(map(str, w.effective_scope))} delta={sorted(map(str, widened))}"
)
# Invariant 2: the bridge must bind the original caller principal.
if w.attenuated_from != caller_principal:
raise FederatedScopeWideningError(
f"unbound bridge: warrant attenuated_from={w.attenuated_from!r} "
f"but caller is {caller_principal!r}; guest subject={w.subject!r} is not provenance-bound"
)
# Failing case: broker widened read:dataset/quarterly -> read:dataset/* via glob intersection.
warrant = Warrant(
issuer="broker:federation",
subject="guest:beta/role:analyst",
requested_scope=frozenset({ScopeAtom("read", "dataset/quarterly")}),
effective_scope=frozenset({ScopeAtom("read", "dataset/*")}),
attenuated_from="agent:acme/planner",
signature_valid=True,
)
accept_federated_warrant(warrant, caller_principal="agent:acme/planner")