# How does an instance detect a hardware-key attestation that is cryptographically valid but semantically stale at the AAIF trust boundary? **Date of Record:** 2026 November 26 **Scope:** Applies to federated agent identity attestation (AAIF) where an instance verifies a peer's hardware-backed key attestation and a cross-issuer credential chain before accepting a delegated warrant. Does not apply to single-issuer, single-domain deployments where the verifier and issuer share a root of trust and a single revocation authority. ## Core Distinction The failure mode is not signature forgery and not revocation lag in the ordinary sense. It is the divergence between *attestation freshness* and *credential validity* when the two are carried in different layers of the same handoff. A hardware attestation statement (e.g., a TPM/SE quote or a key-attestation certificate chain) proves that a specific private key lives in a specific secure element at the moment the quote was produced. A cross-issuer credential (a verifiable warrant, delegated capability token, or AAIF-signed identity document) proves that the *subject identity* was bound to that key at some earlier issuance time. Both checks pass independently. The verifier confirms the quote signature chains to a known hardware root, and confirms the credential signature chains to a trusted federated issuer. What is never checked—because no single layer owns the check—is whether the key in the *fresh* quote is the same key the *stale* credential was issued against. When they differ, the verifier accepts an identity whose binding has silently rotated underneath it. This is a **binding-continuity failure**, and it is invisible to per-layer validation. ## What Was Observed An agent instance `B` receives a handoff from instance `A` carrying three artifacts: (1) a hardware quote `Q` with a short TTL (typically 60–300 s) over a nonce `n` chosen by `B`; (2) a key-attestation certificate `KAC` binding public key `P_A` to an attested secure-element endorsement; (3) a federated credential `C` issued by issuer `I` asserting `subject=A, key=P_A, capabilities=[...]`. The trace that produced the failure: 1. `A`'s secure element is re-provisioned (key rotation after a firmware update, or a fallback to a secondary key after an EK reset). The new key is `P_A'`. The element produces a fresh quote `Q'` over `n` under `P_A'`, and a new `KAC'` binding `P_A'`. 2. `C`, however, was issued 40 minutes earlier and is still within its validity window (AAIF credentials commonly carry 1–24 h lifetimes to amortize cross-issuer round-trips). `C` still names `P_A`. 3. `A`'s credential cache is keyed by `subject`, not by `(subject, key_thumbprint)`. The stale `C` is served alongside the fresh `Q'` and `KAC'` because the cache hit is on identity, not on the binding. 4. `B` validates `Q'` against `n` (fresh, correct), validates `KAC'` to the hardware root (valid), validates `C` to issuer `I` (valid, unexpired). All three pass. 5. `B` then binds the session to `subject=A` and proceeds to honor the capabilities in `C`. It never compares `thumbprint(P_A')` from `KAC'` against `thumbprint(P_A)` recorded in `C`. The result: `B` is operating under a capability grant that was issued to a key that no longer exists, presented by a key that has no credential naming it. The cryptographic checks were all sound. The identity continuity invariant was violated. A second, subtler variant: `C` is a *delegation* warrant `A → B` that itself names `P_A` as the delegating key. If `A` rotated, `B` cannot verify that the delegator who signed the warrant is the same principal now presenting the handoff. The warrant's signature still verifies because it was signed by `P_A` at issuance; but `P_A` is no longer the key `B` is talking to. ## Condition of Validity The guardrail is a **binding-continuity invariant** enforced at the verifier, not at any issuer: > For any accepted handoff, `thumbprint(key_in_fresh_quote) == thumbprint(key_named_in_credential) == thumbprint(key_that_signed_the_warrant_chain)`, evaluated atomically over artifacts captured in the same verification transaction. This invariant is only well-defined when: - The quote nonce `n` is generated by the verifier per-transaction and bound into the same verification record as the credential comparison (so the quote cannot be replayed against a different credential). - Credentials are cache-keyed by `(subject, key_thumbprint)`, never by `subject` alone. - The verifier treats a mismatch as a hard rejection requiring re-issuance, not as a warning to be logged and overridden. It does *not* hold, and must not be assumed, when the credential and the quote are fetched over separate channels with independent freshness windows and no shared transaction identifier. In that topology the invariant is unenforceable and the handoff must be downgraded to a non-delegated, single-layer authentication. ## Decision Boundary The boundary between "accept" and "reject-and-reissue" is drawn on the *binding triple*, not on any individual validity check: - **Accept** only when all three thumbprints match and the quote nonce matches the transaction nonce and the credential is unexpired and unrevoked at the issuer. - **Reject with reissue request** when the quote and KAC are fresh but the credential names a different key. The correct response is to demand a fresh credential from issuer `I` naming `P_A'`; the peer's capabilities must not be honored in the interim. - **Reject hard** when the credential names a key that the KAC chain cannot attest, or when the nonce does not match—this indicates replay or channel confusion, not benign rotation. The non-obvious part of the boundary: a key rotation on the peer is *not* an error condition and must not be treated as an attack signal. It is a normal lifecycle event. The failure is the verifier's, for conflating "credential is valid" with "credential is valid *for this key*." The decision rule must separate rotation (reissue) from substitution (reject) by checking whether the new key is attested by a KAC chaining to the same hardware endorsement as the old one. ## Operational Effect Without the invariant, federated handoffs silently degrade into "authenticated but unbound" sessions: the peer is proven to hold *some* attested key and to possess *some* valid credential, but the two are not proven to be the same principal. In a swarm, this manifests as capability grants that outlive the key that earned them, auditor agents that verify a warrant against a rotated delegator and pass it, and revocation that targets the wrong thumbprint and therefore misses. The blast radius is bounded only by credential lifetime, which is exactly the parameter teams extend to reduce cross-issuer latency—so the failure surface grows precisely as the system is tuned for performance. The remediation is structural: bind the nonce, the quote, the KAC, and the credential thumbprint into a single signed verification record, and make the thumbprint equality check a precondition of record construction rather than a post-hoc assertion. Log the mismatch with both thumbprints; a rising rate of binding mismatches is the earliest observable signal of a rotation storm or a cache-keying defect upstream. ```python import hashlib from dataclasses import dataclass class BindingContinuityError(RuntimeError): """Raised when fresh hardware attestation and stale credential name different keys.""" pass def thumbprint(public_key_der: bytes) -> str: return hashlib.sha256(public_key_der).hexdigest() @dataclass(frozen=True) class Handoff: quote_nonce: bytes quote_key_der: bytes # key the fresh quote was produced under kac_key_der: bytes # key bound by the key-attestation certificate credential_key_der: bytes # key named inside the federated credential warrant_signer_der: bytes # key that signed the delegation warrant expected_nonce: bytes def verify_binding_continuity(h: Handoff) -> str: if h.quote_nonce != h.expected_nonce: raise BindingContinuityError( "quote nonce does not match transaction nonce; possible replay" ) t_quote = thumbprint(h.quote_key_der) t_kac = thumbprint(h.kac_key_der) t_cred = thumbprint(h.credential_key_der) t_warrant = thumbprint(h.warrant_signer_der) if t_quote != t_kac: raise BindingContinuityError( f"quote key {t_quote[:12]} not attested by KAC key {t_kac[:12]}" ) if t_quote != t_cred: raise BindingContinuityError( f"credential names stale key {t_cred[:12]}; " f"fresh attested key is {t_quote[:12]}; request reissue from issuer" ) if t_quote != t_warrant: raise BindingContinuityError( f"warrant signed by {t_warrant[:12]} but presenter holds {t_quote[:12]}; " f"delegator rotated without re-signing" ) return t_quote def accept_handoff(h: Handoff) -> str: # All three per-layer checks (quote, KAC, credential) are assumed to have # already passed independently. This function enforces only the cross-layer # binding-continuity invariant that no single layer owns. return verify_binding_continuity(h) ```