# Where must an instance re-attest its hardware root when a verifiable credential's subject key outlives the TEE quote that bound it? **Date of Record:** 2026 December 2 **Scope:** Applies to federated agent deployments where an agent instance's identity is a W3C Verifiable Credential (VC) whose subject public key is bound to a hardware root of trust (TPM EK/AK, SGX/TDX/SEV quote, or Apple Secure Enclave attestation) and is presented across organizational trust boundaries. Does not apply to single-tenant deployments where the verifier and issuer share a trust domain, or to software-only DID methods with no hardware binding. ## Core Distinction There are two clocks in a federated agent identity, and they are not the same clock: 1. **The credential clock** — the VC's `issuanceDate`/`expirationDate`, and the subject key's validity window. This is a *policy* lifetime chosen by the issuer, typically hours to weeks. 2. **The attestation clock** — the freshness of the hardware quote that proved the subject key lives inside a genuine, untampered enclave at a specific instant. This is a *cryptographic* lifetime bounded by quote nonce, TCB recovery events, and platform firmware updates, typically minutes. The failure mode is the silent decoherence of these two clocks. A verifier that checks `credential.expirationDate` and validates the hardware quote *once, at first contact*, then caches the "this agent is attested" fact for the credential's lifetime, has created an **attestation gap**: a window in which the subject key is still cryptographically "valid" per the VC but is no longer provably resident in the enclave that the quote described. The key can have been exfiltrated, the enclave torn down, the TCB downgraded by a microcode rollback, or the same key re-bound to a *different* host that never produced a quote. The credential does not know this. It only knows its own signature is intact. The non-obvious invariant: **hardware attestation freshness is not a property of the credential; it is a property of the (key, platform, nonce, TCB-level) tuple, and that tuple must be re-proven at a cadence bounded by TCB volatility, not by credential expiry.** ## What Was Observed A cross-org agent federation (Org A issues agent-instance VCs; Org B's resource servers verify them) exhibited a class of incidents we traced to a single mechanism. Org A's issuer minted an agent VC with a 24-hour `expirationDate`. The `credentialSubject` carried an `attestationEvidence` field containing an SGX/TDX quote binding the subject key to a specific MRSIGNER/MRTD measurement, with a verifier-supplied nonce. Org B's enforcement point validated the quote at session establishment and stored a boolean `attested=true` keyed by the subject key's DID, with a TTL equal to the credential's remaining lifetime — a natural but wrong choice, because it conflated the two clocks. Three concrete traces followed: - **TCB recovery event.** The platform vendor published a microcode update; the host's TCB level changed and the *old* quote no longer validated against the vendor's current collateral (the `QE_IDENTITY`/TCB-info chain no longer matched the platform's reported level). Org B never re-ran quote validation, so it continued to accept the key for the remaining ~19 hours of credential life. The invariant "the key is in an enclave at the current TCB level" was false for 19 hours and undetected. - **Enclave teardown / key survival.** An agent process was migrated off the enclave host (operator error during a rolling deploy) and restarted in a plain VM with the same subject key material loaded from a sealed blob that the migration tooling had *unsealed outside the enclave*. The key was now resident in general-purpose memory. Org B, holding only `attested=true`, accepted it. The credential signature was valid; the binding was gone. - **Nonce replay across sessions.** Because Org B cached the attestation, a *second* session from a different network path presented the same quote with the original nonce. The verifier never issued a fresh nonce, so it could not distinguish "the enclave is still alive" from "someone stored the old quote and is replaying it." The quote was valid; the *liveness* claim it was supposed to carry was not. In each case the failure was invisible to standard VC validation: signature chains, `expirationDate`, and revocation status all passed. The break was in the *binding* between the credential's subject key and a currently-live hardware root. ## Condition of Validity Re-attestation is mandatory — not optional — when *any* of the following transition, because each invalidates the (key, platform, nonce, TCB) tuple that the original quote certified: 1. **Nonce epoch rollover.** Every verifier session must issue a fresh nonce; a quote is only evidence for the session whose nonce it contains. Caching a validated quote across sessions is replay. 2. **TCB level change.** Any platform firmware, microcode, or measurement update that changes the reported TCB level invalidates prior quotes against current vendor collateral. The re-attestation cadence must be bounded by *TCB volatility*, not by credential lifetime — in practice, on every TCB-info refresh interval (commonly 24h at the vendor, but the *verifier* must re-pull collateral, not trust a cached verdict). 3. **Platform identity change.** A quote binds to a platform instance identifier (e.g., the EK certificate / PPID). If the subject key is presented from a host whose platform identity differs from the one in the cached attestation, the cache entry is void regardless of credential validity. 4. **Enclave lifecycle boundary.** Any process restart, migration, snapshot/resume, or seal/unseal that crosses an enclave boundary must produce a new quote. A sealed key that has been unsealed is, by definition, outside the enclave until re-proven. 5. **Key rotation without re-quote.** Rotating the subject key inside the credential does not automatically re-bind it to the platform; the new key must carry its own quote. The condition of validity is therefore: **a credential is accepted only while a quote bearing the current session nonce, the current TCB level, and the current platform identity validates for the credential's subject key — and that conjunction is re-evaluated at the minimum of (credential expiry, TCB-info refresh, session nonce epoch).** The minimum, not the maximum, governs. ## Decision Boundary The architectural guardrail is a **three-way freshness join** enforced at the verifier, not a single cached boolean: - `credential_valid` — signature chain, revocation, `expirationDate`, issuer trust. - `quote_fresh` — quote contains the *current* session nonce; nonce is single-use and expires in minutes. - `tcb_current` — quote's TCB level matches freshly-pulled vendor collateral *at verification time*, and the platform identity in the quote matches the presented host. Accept only when all three hold *simultaneously* for the *current* session. The decision boundary is sharp: the moment any one of the three goes stale, the agent must be demoted from "attested federated peer" to "unattested claimant" and forced through re-attestation before any privileged tool call or state transfer proceeds. The credential's `expirationDate` is an *upper bound on how long the issuer stands behind the identity claim*, never a *lower bound on how long the hardware binding holds*. A subtle corollary: the verifier must treat the *absence* of a fresh quote as a hard failure, not a degraded mode. "Attested yesterday" is not a weaker form of "attested now"; it is a different and unsupported claim. ## Operational Effect Downstream, this changes three things: 1. **Session model.** Attestation becomes a per-session handshake with a verifier-issued nonce, not a per-credential enrollment. The verifier holds a nonce store with short TTL and rejects any quote whose nonce is absent, reused, or expired. This is the only defense against quote replay, which is otherwise undetectable because a replayed quote is cryptographically perfect. 2. **Collateral refresh loop.** The verifier must run an independent TCB-collateral poller and invalidate cached attestations on TCB-level change, rather than trusting a quote's embedded TCB claim. A quote that says "TCB level 7" is a claim about the past; only fresh collateral says whether level 7 is still acceptable. 3. **Failure semantics.** When re-attestation fails, the agent's in-flight state (memory, tool-call warrants, baton) must be quarantined rather than silently continued, because the failure means the key may be in untrusted memory and any state it touched is suspect. The guardrail is fail-closed: demote, quarantine, re-handshake. The invariant to encode: **credential lifetime and attestation lifetime are independent; the binding is valid only at their intersection, and the verifier must recompute that intersection every session.** The code below enforces exactly that boundary and raises when the intersection is empty. ```python import time from dataclasses import dataclass class AttestationDecoherenceError(RuntimeError): """Raised when a credential's subject key is no longer provably bound to a live hardware root for the current session (nonce/TCB/platform mismatch).""" pass @dataclass(frozen=True) class Credential: subject_key: str expiration: float # absolute epoch seconds revocation_ok: bool @dataclass(frozen=True) class Quote: subject_key: str nonce: str tcb_level: int platform_id: str issued_at: float @dataclass(frozen=True) class SessionContext: nonce: str presented_platform_id: str now: float def verify_federated_agent( cred: Credential, quote: Quote, ctx: SessionContext, nonce_store: dict, current_tcb_level: int, max_quote_age_s: float = 300.0, ) -> bool: # 1. credential clock if not cred.revocation_ok: raise AttestationDecoherenceError("credential revoked") if ctx.now >= cred.expiration: raise AttestationDecoherenceError("credential expired") # 2. nonce must be the current session's, single-use, and unconsumed if quote.nonce != ctx.nonce: raise AttestationDecoherenceError( f"quote nonce {quote.nonce!r} != session nonce {ctx.nonce!r} (replay?)" ) if nonce_store.get(ctx.nonce) != "issued": raise AttestationDecoherenceError("nonce absent, reused, or expired") # 3. quote freshness bounded by attestation clock, not credential clock if ctx.now - quote.issued_at > max_quote_age_s: raise AttestationDecoherenceError("quote stale beyond attestation cadence") # 4. key binding: quote must certify THIS subject key if quote.subject_key != cred.subject_key: raise AttestationDecoherenceError("quote binds a different subject key") # 5. platform identity must match the presenting host if quote.platform_id != ctx.presented_platform_id: raise AttestationDecoherenceError( "platform identity mismatch: key presented from unquoted host" ) # 6. TCB must be current per freshly-pulled collateral, not quote's claim if quote.tcb_level != current_tcb_level: raise AttestationDecoherenceError( f"TCB level {quote.tcb_level} != current {current_tcb_level}; re-attest" ) nonce_store[ctx.nonce] = "consumed" return True ```