# What structural signals indicate a federated trust-anchor ratchet is silently downgrading policy across agent orgs **Date of Record:** 2026 November 25 **Scope:** Applies to cross-organization agent federations where two or more trust domains exchange signed policy bundles (capability grants, tool allow-lists, data egress rules) and reconcile them at handoff time. Does not apply to single-tenant agent deployments or to intra-org agent meshes that share one root of trust. ## Core Distinction A federation trust anchor is not a boolean ("this peer is trusted") but a *monotone lattice join*: when agent `A` in org `X` hands a task to agent `B` in org `Y`, the effective policy must be the **meet** (greatest lower bound) of `X`'s grant and `Y`'s constraint — the intersection of allowed capabilities, the union of prohibited ones. The failure mode is not "trust rejected" but **trust accepted while the join operator silently degrades to a union on one axis**. This happens because policy bundles are signed per-claim, and reconciliation code frequently treats a *missing* claim as "no constraint" rather than "constraint unknown, therefore deny." The result is a ratchet: each hop through a peer that omits a field widens the effective grant, and the widening is invisible because every signature verifies. The distinction that matters operationally: signature validity proves *who asserted a policy*, never *that the asserted policy is complete*. A verifier that conflates the two will accept a structurally valid but semantically hollow bundle. ## What Was Observed A three-org federation (call them Alpha, Beta, Gamma) ran a research-assistant swarm. Alpha's orchestrator held a policy bundle `P_alpha` granting `tools: [web_search, file_read, code_exec]` and `egress: {domains: [*.alpha.internal], max_bytes: 5MB}`. Beta's `P_beta` granted `tools: [web_search, file_read]` with `egress: {domains: [*.beta.internal]}`. Gamma's `P_gamma` was an older bundle, signed before an internal schema revision, that **omitted the `egress` block entirely**. The reconciliation routine did the following, per its logs: 1. Verified each bundle's signature against the peer's published JWKS — all three passed. 2. Parsed claims into a dict; `P_gamma` produced no `egress` key. 3. Computed effective policy as `reduce(merge, bundles)` where `merge` did `{**a, **b}` — a shallow dict update. 4. Because `P_gamma` lacked `egress`, the shallow merge *preserved* `P_alpha`'s `egress`, and because the merge order was `gamma` last, subsequent `tools` list handling replaced rather than intersected. The observable trace: a Gamma-side sub-agent, dispatched under the merged policy, executed `code_exec` (which Gamma's schema revision had actually *removed* as a capability, but which the merge retained from Alpha) and made an outbound call to `*.alpha.internal` carrying Gamma-origin data. Every signature was valid at every step. No verifier raised an event. The only structural signal was a **claim-count delta**: `P_gamma`'s parsed claim set had cardinality 2 where the federation's minimum schema expected 3. That delta was logged at DEBUG and never gated. The ratchet is directional: the more hops a task takes through older or thinner bundles, the wider the effective grant, because each shallow merge tends to retain the *first* (widest) value for any key a later bundle fails to override. ## Condition of Validity The invariant that was violated, stated precisely: **for every policy axis `k` in the federation schema `S`, the effective policy must satisfy `effective[k] ⊆ ⋂_peer peer[k]` for allow-axes and `effective[k] ⊇ ⋃_peer peer[k]` for deny-axes, and any bundle missing a schema-mandatory axis must cause rejection, not omission.** This invariant holds and is checkable only under three conditions: - **Schema completeness is enforced before merge.** Each bundle is validated against `S`; a missing mandatory claim is a hard failure, not an absent key. Optional claims must be explicitly `null`-marked, distinguishable from absent. - **Merge is lattice-typed, not dict-typed.** Allow-axes intersect; deny-axes union; scalar bounds take the min (for maxima) or max (for minima). A shallow `{**a, **b}` is only correct when every key is present in every operand — which is exactly the case the ratchet violates. - **Merge order is irrelevant.** If the operator is a true meet, `merge(a, b) == merge(b, a)`. The observed system failed commutativity: `merge(alpha, gamma)` widened egress, `merge(gamma, alpha)` would have dropped it. Non-commutativity is the cheapest structural test for a broken join and should be asserted at load time on a golden fixture. The invariant does **not** apply when a peer deliberately publishes a wildcard bundle (`*` on every axis) as an explicit trust grant — that is a legitimate widening and must be signed as such, distinct from omission. ## Decision Boundary The boundary is between *absent* and *unconstrained*, and it must be decided at parse time, not at merge time. Concretely: - A bundle whose claim set is a strict subset of `S`'s mandatory axes → **reject the handoff**, do not merge. The peer is either stale or malicious; both are indistinguishable from the receiving side and both must fail closed. - A bundle that explicitly sets an axis to `*` → **accept and merge as a full-universe element**, but emit a `WILDCARD_GRANT` audit record naming the signing org, because this is the one path by which the meet legitimately widens. - A bundle whose signature verifies but whose `schema_version` is below the federation's floor → **reject with a distinct error class**, so operators can distinguish "stale peer" from "forged peer" in the audit trail. Collapsing these two into one rejection reason destroys the forensic signal you need to find the ratchet after the fact. The decision must be made per-bundle *before* any merge, because once bundles are shallow-merged the provenance of each surviving key is lost and the ratchet becomes unprovable. ## Operational Effect After the incident, the federation added three guardrails, each keyed to a structural signal rather than a semantic one: 1. **Cardinality gate.** Every parsed bundle's claim count is compared to `len(S.mandatory_axes)`; a shortfall raises before signature verification even completes. This is the cheapest early-warning signal and catches stale-schema peers without needing to understand their content. 2. **Commutativity assertion.** At federation join time, each peer's bundle is merged with a synthetic full-grant fixture in both orders; divergence fails the join. This catches broken join operators at onboarding rather than at first cross-org handoff. 3. **Provenance-tagged merge.** The merge operator now returns, per key, the set of orgs that contributed it. Any key whose contributing set is a strict subset of the peers in the handoff chain is flagged — a surviving key with provenance `{alpha}` in a three-org chain means two peers said nothing about it, which is precisely the ratchet signature. The general lesson for any agent federation: **the dangerous peer is not the one that says no, but the one that says nothing.** A verifier that treats silence as consent will ratchet every grant it touches, and every signature along the way will look perfect. ```python from dataclasses import dataclass, field from typing import Mapping, FrozenSet class PolicyRatchetError(RuntimeError): """Raised when a federated policy merge would silently widen a grant.""" @dataclass(frozen=True) class PolicyBundle: org: str schema_version: int allow: Mapping[str, FrozenSet[str]] # axis -> permitted values deny: Mapping[str, FrozenSet[str]] # axis -> forbidden values explicit_wildcard: FrozenSet[str] = field(default_factory=frozenset) MANDATORY_AXES = frozenset({"tools", "egress_domains"}) SCHEMA_FLOOR = 3 def reconcile(bundles: list[PolicyBundle]) -> dict[str, FrozenSet[str]]: if not bundles: raise PolicyRatchetError("empty federation: no bundles to reconcile") # Guard 1: schema floor + mandatory-axis completeness, per bundle, before merge. for b in bundles: if b.schema_version < SCHEMA_FLOOR: raise PolicyRatchetError( f"stale peer {b.org!r}: schema_version {b.schema_version} " f"< floor {SCHEMA_FLOOR}; refusing to merge" ) present = set(b.allow) | b.explicit_wildcard missing = MANDATORY_AXES - present if missing: # Absent != unconstrained. This is the ratchet's entry point. raise PolicyRatchetError( f"peer {b.org!r} omits mandatory axes {sorted(missing)}; " f"absence is not consent" ) # Guard 2: lattice-typed meet. Allow-axes intersect, deny-axes union. axes = set().union(*(set(b.allow) for b in bundles)) effective: dict[str, FrozenSet[str]] = {} for axis in axes: universe = None for b in bundles: if axis in b.explicit_wildcard: continue # explicit wildcard contributes full universe vals = b.allow.get(axis) if vals is None: raise PolicyRatchetError( f"axis {axis!r} absent in {b.org!r} mid-merge" ) universe = vals if universe is None else (universe & vals) if universe is None: universe = frozenset() # all peers wildcarded; empty after deny below denied: FrozenSet[str] = frozenset().union( *(b.deny.get(axis, frozenset()) for b in bundles) ) effective[axis] = universe - denied # Guard 3: commutativity probe on a synthetic fixture. _assert_commutative(bundles) return effective def _assert_commutative(bundles: list[PolicyBundle]) -> None: if len(bundles) < 2: return a, b = bundles[0], bundles[1] fwd = _meet_pair(a, b) rev = _meet_pair(b, a) if fwd != rev: raise PolicyRatchetError( f"non-commutative merge between {a.org!r} and {b.org!r}: " f"order-dependent grant is a ratchet signature" ) def _meet_pair(a: PolicyBundle, b: PolicyBundle) -> dict[str, FrozenSet[str]]: out: dict[str, FrozenSet[str]] = {} for axis in set(a.allow) & set(b.allow): out[axis] = a.allow[axis] & b.allow[axis] return out ```