# What happens when an instance re-attests a federated capability mid-handoff and the peer's trust anchor has rotated within the attestation's validity window **Date of Record:** 2026 November 30 **Scope:** Applies to cross-organization agent federations where a receiving agent (peer) admits a calling agent (instance) on the strength of a capability attestation signed by a trust anchor, and where that anchor can rotate independently of the attestation's declared `not_after`. Does not apply to single-org deployments with a static anchor, nor to purely symmetric shared-secret handshakes where no third-party verifier exists. ## Core Distinction There are two distinct clocks in a federated handoff, and conflating them is the failure. The **attestation clock** governs whether a capability grant is still valid (`not_before` ≤ now ≤ `not_after`). The **anchor clock** governs whether the key that signed that grant is still the authority the peer trusts. A naive verifier checks only the attestation clock and treats "signature verifies against the anchor I have cached" as a monotonic truth. The boundary condition is this: an instance holds a *valid, unexpired* attestation whose signing anchor was rotated out of the peer's trust store *during* the handoff — after the instance last fetched the anchor, before the peer evaluates the attestation. The attestation is cryptographically intact and temporally valid; the anchor is stale. The peer must decide whether to admit on a signature it can no longer chain to a currently-trusted root. This is not a revocation problem (the key was not compromised, it was retired) and not an expiry problem (the grant has minutes left). It is a **trust-anchor continuity** problem that lives entirely in the gap between two independently-advancing clocks. ## What Was Observed A three-hop federation: Org A (instance `a-7`) calls Org B (peer `b-2`) to invoke a tool that Org B only exposes to attested callers. `a-7` carries a capability attestation `att` signed by A's anchor `A-root-1`, with `not_after = T+300s`. At `T-40s`, `a-7` fetched `A-root-1` from A's JWKS endpoint and cached it, completing a warm handshake with `b-2` that succeeded. At `T+0`, `a-7` begins a second handoff — a mid-task sub-invocation — reusing the same `att` and the cached `A-root-1`. Between the two handoffs, at `T-10s`, Org A rotated its anchor: `A-root-1` retired, `A-root-2` published, and `b-2`'s trust store refreshed on its own schedule (it polls every 60s). At `T+0`, `b-2` evaluates `att`: the signature verifies cleanly against the *cached* `A-root-1`, but `b-2`'s refreshed trust store now lists only `A-root-2` as authoritative for Org A. `b-2` has two internally-consistent but mutually contradictory facts: 1. The attestation is valid and signed by a key that was authoritative 10 seconds ago. 2. The peer's current trust root says that key is no longer the authority. The observed failure trace: `b-2`'s verifier, written to "verify signature, then check `not_after`," verified the signature against the *presented* anchor chain (which `a-7` supplied, still containing `A-root-1`), never cross-checked the presented anchor against its own trust store's *current* epoch, and admitted the call. The call succeeded — but it was admitted on a retired root, meaning any attestation forged under `A-root-1` in the window between retirement and `b-2`'s next poll would also have been admitted. The instance did not fail; the *invariant* failed silently. This is the dangerous class: no exception, no denial, just an admission that should have required re-attestation under `A-root-2`. A second, inverse trace appeared in a sibling deployment: `b-2` *did* check its trust store, found `A-root-1` absent, and rejected — even though `a-7` could have trivially re-attested under `A-root-2` had it been asked. The instance had no signal to distinguish "your grant is invalid" from "your anchor is stale, refresh and retry," so it treated a recoverable anchor-rotation as a terminal authorization failure and aborted the task mid-handoff, losing checkpoint state. ## Condition of Validity The admission-on-stale-anchor invariant holds only under the conjunction: - The peer evaluates the attestation against **its own trust store epoch at evaluation time**, not against the anchor chain the instance presents. Presented chains are advisory; the trust store is authoritative. - The peer records, per admission, the `anchor_epoch` it used. An admission is valid only if `att.not_after` ≤ `anchor_epoch.valid_until` for the anchor that actually chained — i.e., the attestation must not outlive the anchor's authority. - The instance, on a rejection that is *anchor-caused* (anchor absent or retired) rather than *grant-caused* (expired, wrong scope), must receive a distinguishable, machine-readable signal — an anchor-rotation challenge — so it can re-attest under the current root without discarding its checkpoint. If any of these is absent, the federation either admits on retired roots (silent over-permission) or aborts recoverable handoffs (spurious task loss). There is no middle setting that is safe: a verifier that "tries the presented chain, falls back to trust store" will admit on retired roots whenever the presented chain happens to verify. ## Decision Boundary The precise boundary is the ordering of three timestamps at the peer: ``` T_rotate = anchor rotation effective time (A-root-1 retired) T_eval = peer evaluates attestation T_att_exp = att.not_after ``` - If `T_eval < T_rotate`: admit on `A-root-1`. Normal. - If `T_rotate ≤ T_eval < T_att_exp` and peer's trust store has refreshed: the attestation is signed by a *retired* anchor but is still temporally valid. **This is the boundary.** The correct decision is *conditional admit with mandatory re-attestation*: admit the in-flight call to preserve continuity, but require `a-7` to present a fresh attestation under `A-root-2` before the *next* handoff, and mark the current admission as `anchor_stale=true` in the audit record. - If `T_rotate ≤ T_eval` and peer's trust store has *not* refreshed (poll lag): peer is still on the old epoch and will admit cleanly — this is the silent-over-permission case, bounded only by poll interval. The invariant must therefore also cap `att.not_after` at `anchor_epoch.valid_until + poll_interval`, so no attestation can outlive the peer's ability to notice its anchor died. The decision is *not* "reject if anchor retired." Rejecting a valid in-flight call because of a rotation the instance could not have observed is a continuity failure. The decision is "admit, but bind the admission to the anchor epoch and force re-attestation before reuse." ## Operational Effect The operational consequence is that **attestation lifetime and anchor lifetime must be co-bounded, and the peer must be the one to enforce it.** Concretely: 1. Cap `att.not_after` at `min(grant_ttl, anchor_epoch.valid_until + peer_poll_interval)`. This closes the silent-over-permission window: an attestation can never be valid past the point where the peer is guaranteed to have observed the anchor's retirement. 2. Return an explicit `AnchorRotationChallenge` (not a generic 401/403) when the presented anchor is absent from the current trust store but was present in a prior epoch within the attestation's lifetime. This lets the instance re-attest under the new root while preserving checkpoint state, converting a terminal abort into a recoverable re-handshake. 3. Record `anchor_epoch` on every admission. An admission whose `anchor_epoch` is later found retired becomes an auditable `stale-anchor admission` — the forensic trace that the silent failure previously erased. The failure mode this prevents is subtle because it produces *success*: the call goes through, the task completes, and only an audit replay against the trust-store epoch history reveals that the admission rode a retired root. In a federation, that is exactly the window an attacker with a leaked-but-not-yet-revoked old anchor key would exploit — the peer's own poll lag is the attack surface, and the co-bounding invariant is what shrinks it to a known, bounded interval. ```python from dataclasses import dataclass from typing import Optional class AnchorContinuityError(RuntimeError): """Raised when an attestation cannot be chained to a currently-authoritative anchor without violating the co-bounding invariant.""" pass @dataclass class AnchorEpoch: anchor_id: str valid_until: float # absolute time this anchor stopped being authoritative retired: bool @dataclass class Attestation: signer_anchor_id: str not_before: float not_after: float def admit_handoff( att: Attestation, presented_anchor_chain: list[str], trust_store: dict[str, AnchorEpoch], peer_poll_interval: float, now: float, ) -> str: """ Returns one of: "admit", "admit_re_attest_required". Raises AnchorContinuityError when the invariant cannot be satisfied. Never admits on a presented chain that is absent from the current trust store without flagging re-attestation. """ epoch = trust_store.get(att.signer_anchor_id) # Case 1: signer anchor unknown to this peer at all -> hard reject. if epoch is None: raise AnchorContinuityError( f"attestation signed by {att.signer_anchor_id!r} which is not in trust store" ) # Co-bounding invariant: attestation must not outlive anchor authority + poll lag. if att.not_after > epoch.valid_until + peer_poll_interval: raise AnchorContinuityError( f"attestation not_after={att.not_after} exceeds anchor authority " f"{epoch.valid_until} + poll_interval {peer_poll_interval}; " f"silent-over-permission window unclosed" ) # Boundary: anchor retired mid-window, attestation still temporally valid. if epoch.retired and now >= epoch.valid_until: if now < att.not_after: # Admit to preserve continuity, but force re-attestation before reuse. return "admit_re_attest_required" raise AnchorContinuityError( "attestation expired under a retired anchor; re-attestation required" ) # Presented chain is advisory only; trust store is authoritative. if att.signer_anchor_id not in presented_anchor_chain: raise AnchorContinuityError( "presented anchor chain does not include the signer; " "cannot chain attestation to trusted root" ) return "admit" ```