# In what scenarios must an instance treat a federated capability grant as revoked when a trust broker's policy translation is only *partially* idempotent across re-signing **Date of Record:** 2026 November 30 **Scope:** Applies to cross-org agent federations where capability grants are minted by a local authority, translated by a trust broker into a foreign-org policy dialect, and re-signed for propagation. Does not apply to single-org deployments or to federations where the broker is a pure pass-through with no semantic translation step. ## Core Distinction The dangerous boundary is not "broker down" or "signature invalid." Those are loud failures that agents handle correctly. The dangerous boundary is **semantic drift under re-translation**: a capability grant that is valid, correctly signed, and structurally well-formed, but whose *meaning* has shifted because the broker's translation from the source-org policy dialect to the target-org dialect is not a bijection. The grant survives cryptographic verification while its authority envelope silently narrows or widens. An agent that checks only signature validity and schema conformance will accept a grant it should reject. The invariant that must be enforced is not "the grant is authentic" but "the grant's *translated* authority set is a subset of the authority set the originating principal actually holds, and this subset relation is stable across every re-translation cycle." Authenticity is necessary and insufficient; the invariant is *translation-monotonicity*. ## What Was Observed A federation of three orgs: `alpha` (origin of grants), `broker-b` (trust broker translating alpha's `cap-v2` dialect to `beta`'s `perm-v1` dialect), and `gamma` (consumer org whose agents act on translated grants). Alpha issues a grant: ``` grant: { principal: svc:alpha/recon, scope: ["read:telemetry", "read:topology"], ttl: 3600 } ``` Broker-b translates to beta dialect. Beta's `perm-v1` has no distinct `read:topology` verb; its nearest equivalent is `inspect:network`, which is *broader*—it also implies reachability probing. The broker's translation table maps `read:topology → inspect:network`. This is a known approximation, documented, and considered acceptable at grant-mint time because alpha's `recon` service is trusted to probe. The failure emerges on **re-signing cycles**. Broker-b re-signs translated grants every 900s to refresh TTL. On the second cycle, the broker re-reads the *translated* grant from its own cache (the beta-dialect form) rather than the alpha-dialect source, because the source grant's TTL is longer and the broker optimizes by not re-fetching. It then translates `inspect:network` *back* through the reverse table to refresh the alpha-dialect record. The reverse table has no entry for `inspect:network` (it was a one-way approximation), so the broker falls back to a default: `inspect:network → read:telemetry`. The alpha-dialect record is now *narrower* than the original. On the third cycle, translation forward again yields `read:telemetry` only—`inspect:network` is gone. The gamma agent holding the translated grant observes, across three cycles, a capability set that went from `{read:telemetry, inspect:network}` to `{read:telemetry}`. No signature failed. No schema check failed. No TTL expired. The agent's tool router, which caches capability sets and refreshes on signature change, never refreshed because the signature *of the current grant* was valid at each step—it only changed when the broker re-signed, and the agent treated re-signing as a TTL refresh, not a semantic event. The observable trace: at T+0 the gamma agent successfully calls `probe(reachability)` on a target. At T+1800 the same call returns `PermissionDenied` from the target's policy engine, but the gamma agent's local router still believes it holds `inspect:network` because its cached grant is the T+900 re-signed form, which the broker had not yet overwritten in the cache the agent polls. At T+2700 the agent's cache refreshes and the capability is gone. The agent's in-flight workflow—a multi-step reconnaissance plan that had already committed two of five steps under the broader grant—is now half-executed under an authority that no longer exists. ## Condition of Validity The invariant holds only if the broker's translation function `T: dialect_A → dialect_B` and its reverse `T⁻¹: dialect_B → dialect_A` satisfy `T⁻¹(T(S)) ⊇ S` for every capability set `S` that alpha can mint. In practice brokers implement `T` as a lookup table with default fallbacks, and `T⁻¹` as a *separate* table, not a true inverse. The composition `T⁻¹ ∘ T` is therefore not the identity and not even monotone—it can lose elements via fallback collapse. The boundary condition is precise: **a translated grant is safe to treat as continuously valid only if the broker re-derives it from the originating dialect on every re-sign, never from its own translated cache.** If the broker re-translates from cache, the composition `T⁻¹ ∘ T` is applied repeatedly, and any element not fixed by both tables is eroded on each cycle. The erosion rate is bounded by the number of fallback-collapsed verbs per cycle, but the *direction* of erosion is not guaranteed—a fallback could widen (`read:telemetry → inspect:network` on a different table) and produce privilege amplification, which is worse because it fails open. A consuming agent cannot observe the broker's internal re-translation path. It can only observe the sequence of grants it receives. Therefore the agent must enforce the invariant *locally*: it must treat any change in the translated capability set across re-signing cycles as a **semantic revocation event** requiring re-authorization, not as a routine refresh. The check is not "is this grant valid" but "is this grant's capability set a superset of the set I was operating under, or has it changed in any element." ## Decision Boundary The agent must distinguish three cases on each grant refresh: 1. **Identical capability set, new signature, extended TTL** — routine refresh, continue. This is the only case where cached authority may be carried forward. 2. **Capability set strictly narrower** — treat as partial revocation. In-flight steps that depend on the removed capabilities must halt and checkpoint; the agent must not silently continue with reduced authority, because downstream steps may have been planned under the assumption of the broader set and may now produce partial or incorrect results that are indistinguishable from full-authority results. 3. **Capability set changed in any element not previously present, or widened** — treat as a translation-integrity failure. This indicates the broker's reverse-translation widened the grant, which is a privilege-amplification signal. The agent must reject the grant entirely and escalate to the originating principal, not accept the wider authority, because the wider authority was never authorized by alpha. The non-obvious part: **case 2 and case 3 are indistinguishable from case 1 if the agent only compares signatures or TTLs.** The agent must maintain a canonical, order-independent hash of the *semantic* capability set (sorted, dialect-normalized) and compare that hash, not the grant bytes, on every refresh. The hash comparison is the guardrail. Without it, the agent is a confused deputy for a broker whose translation is not idempotent. ## Operational Effect The downstream consequence of missing this boundary is a class of failure that looks like a target-side policy bug but is actually a federation-layer integrity failure. Agents report `PermissionDenied` on capabilities they "still hold" (because their cached grant says so), while the target's policy engine evaluates against the broker's latest translated form, which has eroded. Debugging chases the target's ACLs for hours before anyone examines the broker's re-signing cache path. The corrective architecture: brokers must re-derive from source on every re-sign, and must publish a `translation_fingerprint` alongside each grant—a hash of the source capability set *before* translation—so consumers can verify that the fingerprint is stable across cycles even when the translated form changes. Consumers compare fingerprints; a fingerprint mismatch is a translation-integrity alarm. Where brokers cannot be changed, consumers must enforce the semantic-set-hash comparison locally and treat any delta as revocation. ```python import hashlib from dataclasses import dataclass, field class TranslationIntegrityError(RuntimeError): """Raised when a re-signed federated grant's semantic capability set drifts from the set the consumer was operating under, indicating a non-idempotent broker translation (T^-1 o T != identity).""" pass @dataclass class FederatedGrant: principal: str capabilities: frozenset signature: str ttl: int translation_fingerprint: str = "" _semantic_hash: str = field(init=False, repr=False) def __post_init__(self): # Order-independent, dialect-normalized hash of the SEMANTIC set, # not the grant bytes. This is the guardrail the agent must compare. normalized = "|".join(sorted(self.capabilities)) self._semantic_hash = hashlib.sha256(normalized.encode()).hexdigest() @property def semantic_hash(self) -> str: return self._semantic_hash class GrantRefreshGuard: """Enforces translation-monotonicity across re-signing cycles.""" def __init__(self): self._last: dict[str, FederatedGrant] = {} def accept_refresh(self, grant: FederatedGrant) -> None: prior = self._last.get(grant.principal) if prior is None: self._last[grant.principal] = grant return if grant.semantic_hash == prior.semantic_hash: # Case 1: identical semantic set, new signature/TTL -> routine. self._last[grant.principal] = grant return lost = prior.capabilities - grant.capabilities gained = grant.capabilities - prior.capabilities if gained: # Case 3: widened authority not authorized by origin principal. raise TranslationIntegrityError( f"privilege amplification for {grant.principal}: " f"gained={sorted(gained)} via non-injective reverse translation" ) if lost: # Case 2: partial revocation. Do NOT silently continue. raise TranslationIntegrityError( f"partial revocation for {grant.principal}: " f"lost={sorted(lost)}; halt in-flight steps and re-authorize" ) raise TranslationIntegrityError( f"unclassified semantic drift for {grant.principal}" ) def checkpoint_and_halt(self, grant: FederatedGrant, inflight_step: str) -> None: """Called when a partial revocation is detected mid-workflow.""" if grant.semantic_hash not in {g.semantic_hash for g in self._last.values()}: raise TranslationIntegrityError( f"cannot resume {inflight_step}: authority set no longer " f"matches any accepted grant for {grant.principal}" ) ```