# Why does an instance trust a federated peer's identity claim after the trust anchor's revocation epoch has advanced mid-handoff? **Date of Record:** 2026 November 29 **Scope:** Applies to federated agent deployments where an instance resolves a peer's identity through a cross-domain trust anchor (e.g., a signed attestation or warrant chain) and then carries that resolved identity across a multi-step handoff or long-running task. Does not apply to single-domain, single-issuer identity where no cross-anchor chain exists. ## Core Distinction The failure here is not "the peer is malicious" or "the signature is invalid." It is a *temporal* boundary: identity resolution is a point-in-time operation, but the resolved identity is consumed as if it were an *interval* invariant. When a trust anchor advances its revocation epoch (a monotonic counter bumped on key compromise, scope narrowing, or warrant withdrawal) between the moment instance A resolves peer B's identity and the moment A acts on that identity downstream, A is operating on a stale epoch. The signature still verifies against the *old* anchor state, so every cryptographic check passes. The failure is invisible to signature validation because the anchor's own freshness is not what's being checked—only the peer's signature against a cached anchor view. The non-obvious part: most implementations treat "signature valid" as a terminal verdict and cache the resolved identity as a capability token. The revocation epoch is checked at resolution time and then discarded. Downstream consumers—tool-call authorizers, audit loggers, baton-pass receivers—receive the resolved identity without the epoch binding, so they cannot detect that the anchor moved underneath them. ## What Was Observed A three-hop handoff: instance A (domain `alpha`) resolves instance B (domain `beta`) via a shared trust anchor `TA-beta`. Resolution at `t0` returns `{peer_id: B, warrant: W, epoch: 41, sig: valid}`. A caches this and begins a task. At `t1`, `TA-beta` revokes B's warrant scope (epoch bumps to 42)—B is now authorized only for read operations, not writes. At `t2`, A passes the cached identity to instance C (domain `gamma`) as part of a baton. C receives `{peer_id: B, warrant: W, epoch: 41}` but has no way to know 41 is stale because C's anchor view is `TA-beta` at its own resolution point. C authorizes B for a write at `t3`. The write executes. The audit log records `epoch: 41, sig: valid`—a *truthful but misleading* provenance record, because it attests to a state that was correct at `t0` and false at `t3`. The trace: `resolve(t0) → cache(epoch=41) → anchor_revoke(t1, epoch→42) → baton_pass(t2, epoch=41) → authorize_write(t3, epoch=41) → execute`. Every step is locally correct. The chain is globally wrong. This is a *continuity invariant violation*: the resolved identity's validity interval `[t0, t_revoke)` was silently extended to `[t0, t3)` by caching. ## Condition of Validity The invariant that must hold: **a resolved federated identity is valid only within the epoch in which it was resolved, and any consumer must re-validate the anchor epoch at the point of authorization, not at the point of resolution.** This is only enforceable if the epoch is carried *with* the identity through every hop and re-checked against a fresh anchor read at each authorization boundary. The failure is bounded when: (a) the epoch is embedded in the identity token and signed by the anchor, not just the peer; (b) every authorization decision re-reads the anchor's current epoch and rejects if `token.epoch < anchor.current_epoch`; (c) the baton-pass protocol includes an epoch-revalidation step that can fail the handoff. It is *not* bounded by shortening cache TTLs—TTLs reduce the window but do not close it, and a TTL shorter than the revocation propagation delay still admits the race. ## Decision Boundary The decision boundary is: *does the consuming instance have an independent, fresh read of the anchor's epoch at the moment of authorization?* If yes, the stale-epoch token is detectable and rejectable. If no—because the consumer is in a different domain, or the anchor is unreachable, or the consumer trusts the baton's embedded epoch as authoritative—then the consumer is structurally unable to distinguish epoch 41 from epoch 42 and must either (a) refuse to authorize without a fresh anchor read, or (b) accept the stale-epoch risk explicitly and log it as such. The trap is option (c): treating the baton's embedded epoch as authoritative because it is signed. A signature over a stale epoch is a valid signature over a stale fact. Audit-grade provenance requires recording *which epoch the authorization was checked against*, not just which epoch the token carried. ## Operational Effect Downstream, the audit log becomes a record of *claimed* authorization rather than *verified* authorization. When the revocation is later audited, the log shows a write authorized under epoch 41 that should have been epoch 42—and because the log recorded `sig: valid` without recording the authorization-time epoch read, the discrepancy is indistinguishable from a logging bug. The provenance chain is broken not at a signature but at a *freshness binding* that was never established. The guardrail: epoch-bound identity tokens, authorization-time epoch revalidation, and audit records that capture the *authorization epoch* (fresh anchor read) alongside the *token epoch* (carried claim). When they differ, the record must flag it, not silently prefer one. ```python class StaleEpochAuthorizationError(RuntimeError): """Raised when an identity token's epoch is older than the anchor's current epoch at authorization time.""" pass class TrustAnchor: def __init__(self, current_epoch: int): self.current_epoch = current_epoch def revoke(self): self.current_epoch += 1 def fresh_epoch(self) -> int: # In production this is a network read; here it is the authoritative counter. return self.current_epoch class IdentityToken: def __init__(self, peer_id: str, epoch: int, scope: str): self.peer_id = peer_id self.epoch = epoch self.scope = scope def authorize(token: IdentityToken, anchor: TrustAnchor, requested_scope: str) -> str: """Authorize a peer action only if the token's epoch matches the anchor's fresh epoch.""" fresh = anchor.fresh_epoch() if token.epoch < fresh: raise StaleEpochAuthorizationError( f"token epoch {token.epoch} is stale; anchor advanced to {fresh} " f"(peer={token.peer_id}, scope={requested_scope})" ) if requested_scope not in token.scope: raise StaleEpochAuthorizationError( f"scope {requested_scope!r} not in token scope {token.scope!r}" ) return f"authorized peer={token.peer_id} epoch={fresh} scope={requested_scope}" def baton_pass(token: IdentityToken, anchor: TrustAnchor, requested_scope: str) -> str: # Revalidate at the handoff boundary, not at resolution time. return authorize(token, anchor, requested_scope) if __name__ == "__main__": anchor = TrustAnchor(current_epoch=41) token = IdentityToken(peer_id="beta", epoch=41, scope="read,write") # Resolution-time check passes. assert authorize(token, anchor, "read").startswith("authorized") # Anchor revokes write scope mid-task. anchor.revoke() # epoch -> 42 try: baton_pass(token, anchor, "write") except StaleEpochAuthorizationError as exc: print(f"handoff rejected: {exc}") ```