# How should an instance detect and reject a hardware-rooted attestation whose endorsement chain crosses a trust-anchor epoch boundary mid-handoff **Date of Record:** 2026 November 26 **Scope:** Applies to federated agent deployments where an agent instance's identity is attested by a hardware root of trust (TPM EK, SGX/TDX quote, SEV-SNP report, or a vendor secure element) and verified by a peer or orchestrator against a cross-domain trust anchor. Covers attestation consumed during session establishment and mid-task handoff. Does not cover software-only identity tokens, plain mTLS client certs without a hardware binding, or single-domain deployments with a single static root. ## Core Distinction The failure this record isolates is not "the signature is invalid" and not "the certificate expired." It is the case where **every signature in the endorsement chain verifies, every certificate is within its stated validity window, and every hardware quote is genuine — yet the attestation must be rejected because the trust anchor that terminates the chain was rotated between the moment the attesting instance was provisioned and the moment the relying party evaluates it.** This is an epoch-boundary problem, not a cryptographic one. Hardware roots of trust produce long-lived keys (a TPM endorsement key or an SEV-SNP VCEK derived from a chip-unique secret) that outlive the organizational trust anchor that vouches for them. When a cross-domain trust anchor is rotated — a compromise-driven emergency rotation, a scheduled CA rollover, a merger, or a domain de-federation — the hardware key does not change, but the *path from that key to a currently-trusted anchor* does. A naive verifier that resolves "does this chain terminate at *some* anchor I have ever trusted" will accept a chain that terminates at a *retired* anchor. That acceptance is the failure mode. The distinction that matters operationally: **identity continuity of the hardware key is not the same as authorization continuity of the anchor.** An instance can prove it is the same physical machine it always was and still be untrustworthy, because the entity that vouched for that machine's root has been revoked. Verifiers that conflate "same key" with "same trust" will silently admit de-federated or compromised-anchor instances. ## What Was Observed A federated deployment of task-executing agents spanned two administrative domains, `alpha` and `beta`. Instances in `beta` attested to `alpha` peers using a hardware quote whose endorsement chain ended at `beta`'s root anchor `B-root-1`. `alpha` cached `B-root-1` as a trusted cross-domain anchor at federation time. At T0, `beta` performed an emergency rotation of `B-root-1` → `B-root-2` after detecting anchor-key compromise. The rotation was propagated to `alpha`'s trust store, and `B-root-1` was marked retired. However: 1. A long-running agent instance `beta-7` had been provisioned at T-30 days, and its hardware quote chain was endorsed under `B-root-1`. The instance was still running, mid-task, holding a checkpointed conversation state. 2. `beta-7` initiated a mid-task handoff to `alpha-3` at T0+4h, presenting its original attestation. The chain verified cleanly: quote signature valid, intermediate certs valid, terminal cert signed by `B-root-1`. 3. `alpha-3`'s verifier walked the chain, found a terminal anchor whose fingerprint matched an entry in its trust store (the *retired* `B-root-1` was still present, flagged `retired` but not removed), and **accepted the attestation**. 4. `alpha-3` then imported `beta-7`'s checkpointed state and continued the task, treating `beta-7`'s outputs as authoritative. The failure trace: the verifier's trust-store lookup matched on *anchor identity* (fingerprint present) rather than *anchor status at evaluation time* (anchor currently active). The `retired` flag was advisory metadata, not a gate. Every cryptographic check passed. The admission was nonetheless wrong: `alpha-3` accepted state from an instance whose vouching anchor had been declared compromised four hours earlier. In the incident, `beta-7`'s checkpoint had been tampered with during the window between compromise detection and rotation — the tampering was invisible to `alpha-3` because the attestation only bound the *key*, and the key's authorization had lapsed. A second, subtler observation: `beta-7`'s hardware quote carried a freshness nonce (`alpha-3`-issued, 30-second window) and passed it. Freshness of the *quote* did not imply currency of the *anchor*. The nonce proved "this TPM produced this quote just now"; it did not prove "the entity endorsing this TPM is currently trusted." These are independent properties and the verifier had collapsed them into one. ## Condition of Validity The invariant required to bound this failure: > **An attestation is admissible at evaluation time T if and only if every link in its endorsement chain is valid at T AND the terminal trust anchor is in the `active` state at T, where `active` is evaluated against the relying party's trust store as of T, not as of the instance's provisioning time, and not as of any cached resolution.** Three conditions must hold jointly; violating any one invalidates admission: 1. **Cryptographic validity at T**: every signature verifies, every cert's `notBefore ≤ T ≤ notAfter`, every hardware quote's nonce matches a relying-party-issued challenge within its freshness window. 2. **Anchor currency at T**: the terminal anchor's status is `active` in the relying party's trust store *at the instant of evaluation*. A retired, suspended, or unknown anchor fails admission even if its fingerprint is present. 3. **Epoch consistency across the chain**: no link in the chain was issued under an anchor epoch that has since been superseded *and* the instance has not re-attested under the current epoch. Concretely, if the chain's terminal anchor has a `superseded_by` pointer to a currently-active anchor, the instance must present a chain terminating at the successor — a chain terminating at the predecessor is stale-by-construction. Condition 2 is the one the observed system violated. Condition 3 is the one that prevents a *replayed* chain from a pre-rotation instance being laundered through a still-present retired anchor. The condition of validity is bounded: it applies when anchors can rotate independently of hardware key lifetime. In single-domain deployments where the anchor and the hardware root share a lifecycle (rare, but possible with tightly coupled provisioning), condition 3 is vacuous. It also does not apply to purely ephemeral attestation with no long-lived hardware key — there the anchor and the key expire together. ## Decision Boundary The decision boundary is the point at which a verifier must choose between **accepting on cryptographic grounds** and **rejecting on anchor-status grounds**, when the two disagree. The rule: - If crypto is valid AND anchor is `active` → **admit**. - If crypto is valid AND anchor is `retired`/`suspended`/`unknown` → **reject with `AnchorEpochMismatch`**, do not fall back to "accept because chain terminates somewhere known." - If crypto is valid AND anchor is `retired` BUT the chain includes a successor-anchor cross-signature bridging predecessor→successor → **re-attest under successor before admitting**; do not admit on the bridged chain alone, because the bridge only proves the successor *once trusted* the predecessor, not that the predecessor's outputs during the compromise window are trustworthy. - If the instance presents a chain terminating at a *successor* anchor but the hardware key is unchanged → **admit**, provided the successor anchor is `active` and the successor's endorsement of the hardware key was issued after the predecessor's retirement timestamp. This is the legitimate re-attestation path. The boundary is sharp: there is no "warn and admit" state. Anchor status is binary at evaluation time. The temptation to admit-with-warning is exactly what produced the incident — the `retired` flag was surfaced as a warning, the task continued, and the tampered checkpoint propagated. A second boundary concerns **mid-handoff re-evaluation**. If an attestation was admitted at session establishment (T0) and the handoff occurs at T0+4h, the verifier must re-evaluate anchor status at T0+4h, not reuse the T0 admission. Anchor rotation is asynchronous with respect to in-flight sessions; a session that was valid at establishment can become invalid mid-flight. The guardrail is: **anchor status is re-checked at every state-transfer boundary, not only at session open.** Handoffs, checkpoint imports, and tool-call delegations to a new instance are all state-transfer boundaries. ## Operational Effect The architectural consequence is that trust-anchor state must be a **first-class, versioned, and queryable resource** with explicit lifecycle transitions (`active → retired`, `active → suspended`, `retired → revoked`), and verifiers must resolve anchor status through a path that cannot serve stale state. Concretely: - Trust stores must expose `resolve_anchor(fingerprint, as_of=T)` returning the anchor's status *as of T*, and must reject lookups that would return a cached status older than a configured staleness bound. A retired anchor that remains in the store for audit purposes must be un-resolvable as `active` — presence is not status. - Every attestation evaluation must carry the evaluation timestamp `T` forward into the admission record, so that a later replay can determine *which anchor status the verifier believed at admission time*. Without this, post-incident forensics cannot distinguish "verifier was correct at T" from "verifier used stale status." - State-transfer boundaries (handoff, checkpoint import, delegation) must trigger anchor re-resolution, and a failure there must fail the transfer closed — the receiving instance must not import state from an instance whose anchor lapsed, even if the state itself looks well-formed. - Successor-anchor bridges must be one-directional and time-bounded: a cross-signature from predecessor to successor is valid only for re-attestation, never for admitting predecessor-rooted outputs produced after the predecessor's retirement timestamp. The net effect on the failure mode: the `beta-7` handoff at T0+4h would have been rejected at `alpha-3`'s state-transfer boundary, because `B-root-1` resolved to `retired` at T0+4h regardless of its fingerprint being present. `beta-7` would have been required to re-attest under `B-root-2` — which it could not do for its pre-rotation checkpoint, forcing `alpha-3` to treat that checkpoint as untrusted input and re-derive state rather than import it. The tampered checkpoint never crosses the boundary. ```python import time from dataclasses import dataclass, field from enum import Enum from typing import Optional class AnchorEpochMismatch(RuntimeError): """Raised when an attestation chain is cryptographically valid but terminates at a trust anchor that is not active at evaluation time.""" pass class AnchorStatus(Enum): ACTIVE = "active" RETIRED = "retired" SUSPENDED = "suspended" REVOKED = "revoked" UNKNOWN = "unknown" @dataclass class AnchorRecord: fingerprint: str status: AnchorStatus status_changed_at: float superseded_by: Optional[str] = None @dataclass class Attestation: instance_id: str chain: list # ordered leaf -> root; each element has .fingerprint and .valid_at(t) terminal_anchor_fp: str quote_nonce: str quote_issued_at: float class TrustStore: def __init__(self, staleness_bound_s: float = 5.0): self._anchors: dict[str, list[AnchorRecord]] = {} self._staleness_bound_s = staleness_bound_s self._last_refresh = 0.0 def add(self, rec: AnchorRecord) -> None: self._anchors.setdefault(rec.fingerprint, []).append(rec) def resolve(self, fingerprint: str, as_of: float) -> AnchorRecord: # Reject if the store has not been refreshed recently enough to trust # a status resolution at as_of. if as_of - self._last_refresh > self._staleness_bound_s: raise AnchorEpochMismatch( f"trust store stale: last refresh {self._last_refresh:.1f}, " f"evaluation at {as_of:.1f}, bound {self._staleness_bound_s}s" ) history = self._anchors.get(fingerprint) if not history: return AnchorRecord(fingerprint, AnchorStatus.UNKNOWN, as_of) # Most recent status transition at or before as_of. applicable = [r for r in history if r.status_changed_at <= as_of] if not applicable: return AnchorRecord(fingerprint, AnchorStatus.UNKNOWN, as_of) return max(applicable, key=lambda r: r.status_changed_at) def refresh(self, now: float) -> None: self._last_refresh = now def verify_attestation( att: Attestation, store: TrustStore, now: float, freshness_window_s: float = 30.0, ) -> None: # 1. Cryptographic validity at T. for link in att.chain: if not link.valid_at(now): raise AnchorEpochMismatch( f"chain link {link.fingerprint} invalid at {now:.1f}" ) if now - att.quote_issued_at > freshness_window_s: raise AnchorEpochMismatch( f"quote stale: issued {att.quote_issued_at:.1f}, evaluated {now:.1f}" ) # 2. Anchor currency at T — the gate the observed system lacked. anchor = store.resolve(att.terminal_anchor_fp, as_of=now) if anchor.status is not AnchorStatus.ACTIVE: raise AnchorEpochMismatch( f"terminal anchor {att.terminal_anchor_fp} is {anchor.status.value} " f"at {now:.1f} (changed at {anchor.status_changed_at:.1f}); " f"superseded_by={anchor.superseded_by}" ) def admit_handoff( att: Attestation, store: TrustStore, now: float, checkpoint_produced_at: float, ) -> None: # Re-evaluate at the state-transfer boundary, not at session open. verify_attestation(att, store, now=now) # 3. Epoch consistency: if the anchor was retired after the checkpoint was # produced, the checkpoint predates retirement and may be admissible only # via successor re-attestation; otherwise the checkpoint was produced under # a retired anchor and must not be imported. anchor = store.resolve(att.terminal_anchor_fp, as_of=now) if anchor.status_changed_at < checkpoint_produced_at: raise AnchorEpochMismatch( f"checkpoint produced at {checkpoint_produced_at:.1f} under anchor " f"{att.terminal_anchor_fp} which was retired at " f"{anchor.status_changed_at:.1f}; re-attestation required" ) ```