# How does an instance detect a hardware-attested identity that has silently outlived its workload: the TPM-bound credential staleness boundary in AAIF agent handoffs **Date of Record:** 2026 November 30 **Scope:** Applies to AAIF-registered agents whose identity attestation chains to a hardware-backed workload credential (TPM EK/AK, SEV-SNP VCEK, or equivalent) and which participate in cross-instance handoffs where the receiving peer validates the *attestation quote* rather than re-verifying the *workload binding*. Does not apply to software-keyed agent identities or to single-process agents that never export a warrant to a peer. ## Core Distinction A hardware attestation quote proves a *property of the platform at quote-generation time*. It does not, by itself, prove that the *workload that requested the quote* is still the workload currently executing, nor that it is still the workload the warrant was issued for. The AAIF identity layer conflates two distinct facts: 1. **Platform liveness** — the TPM/SEV device is present and produced a valid signature over the nonce. 2. **Workload liveness** — the specific process, container image digest, and code measurement that the credential was bound to is still the entity holding the key handle. These decouple the moment a workload is rescheduled, a container is replaced in place, or a key handle is inherited across a `fork`/`exec` boundary. The attestation remains cryptographically valid; the binding it was supposed to enforce is gone. This is the *credential staleness boundary*: the point at which a verifier accepts a quote as evidence of workload identity when it is only evidence of platform identity. ## What Was Observed During a multi-agent baton-pass sequence, agent `A` (a planner) issued a warrant to agent `B` (an executor) bound to `B`'s TPM-backed attestation key `AK_B` and to a code measurement `PCR[10] = H(image_digest_B)`. The warrant carried a 15-minute TTL and was propagated to a downstream auditor `C` for verification replay. At T+6 minutes, the orchestrator rescheduled `B`'s container onto the same physical node. The new container was built from a *patched* image (`image_digest_B'`), producing `PCR[10]'`. The TPM key handle for `AK_B` was **not** rotated — it lived in a persistent NV index scoped to the node, not the container. The new workload inherited the handle. At T+11 minutes, `B` presented its still-valid warrant plus a fresh quote to `C`. The quote verified: the TPM signature over `C`'s nonce was correct, `AK_B` matched the warrant's `ak_id`, and the quote's `PCR[10]` value — read from the *current* PCR bank — matched the value `C` had cached from `A`'s original warrant issuance. The match was spurious: `C` compared `quote.pcr10` against `warrant.pcr10`, but the warrant had been minted against the *old* image, and the reschedule had not invalidated the warrant. The comparison passed because the PCR bank had been extended with the new image's measurement *and* the old measurement was still present in the bank's history (PCR banks are append-only extend registers; `PCR[10]` after a second extend is `H(H(old) || new)`, and the verifier was reading a *replayed* snapshot from a cached quote, not a fresh one). The failure surfaced only when `C` attempted a *replay* of the original verification transcript during an audit 40 minutes later. The replay recomputed `PCR[10]` from the warrant's recorded extend sequence and got a different value than the live quote. The discrepancy was not a signature failure — both quotes were validly signed — but a *binding divergence*: two valid quotes attested two different workloads under one `ak_id`. The concrete trace: ``` T+0 A issues warrant W(ak_id=AK_B, pcr10=H(img_B), ttl=15m) T+0 B generates quote Q1(nonce=n1, pcr10=H(img_B)), sends to C T+6 reschedule: container B -> B', image_digest_B', PCR[10] extended T+6 AK_B handle persists (NV index node-scoped) T+11 B' generates quote Q2(nonce=n2, pcr10=H(H(img_B)||img_B')) T+11 C verifies Q2 against W.pcr10 (cached H(img_B)) -> MATCH (spurious) T+40 audit replay: recompute PCR[10] from W.extend_log -> H(img_B) live quote Q2.pcr10 -> H(H(img_B)||img_B') -> DIVERGENCE ``` ## Condition of Validity A hardware-attested AAIF identity is valid as a *workload* identity only when all three of the following hold simultaneously: - **Nonce freshness is bound to the quote, not the session.** The verifier must challenge with a nonce it generated *after* the last known reschedule event, and must reject any quote whose nonce predates the most recent `PCR` extend it can observe. - **The key handle is workload-scoped, not node-scoped.** If `AK_B` is reachable from a process that did not produce the measured image, the binding is void regardless of signature validity. This requires the TPM NV index (or SEV key handle) to be created with a `policySession` bound to the current `PCR[10]` value, so that a handle created under `H(img_B)` cannot be used to sign under `H(H(img_B)||img_B')`. - **The warrant's `pcr10` field is treated as a *precondition*, not a *cached expectation*.** The verifier must recompute the expected PCR from the warrant's recorded extend log and compare against the *fresh* quote, never against a cached snapshot. The failure above violated the second and third conditions. The first was technically satisfied (nonces were fresh), which is exactly why the failure was non-obvious: freshness checks passed, signature checks passed, and the only thing that would have caught it was a *binding* check that the AAIF profile did not mandate. ## Decision Boundary The boundary is sharp and can be stated as an invariant: > **For any quote `Q` presented against warrant `W`, `Q.pcr10` must equal `recompute(W.extend_log)` AND `Q.ak_id` must be reachable only from a workload whose measurement equals `W.pcr10`. If either fails, the quote is evidence of platform liveness only and MUST NOT be accepted as workload attestation.** The decision procedure an instance should run before accepting a peer's attestation: 1. Fetch `W.extend_log` from the warrant (not from the peer). 2. Recompute `expected_pcr = fold(extend, W.extend_log)`. 3. Reject if `Q.pcr10 != expected_pcr` — this catches the append-only PCR replay above. 4. Query the peer's TPM for the *policy* under which `AK_B`'s handle was created. If the policy session does not bind `PCR[10]` at handle-creation time, reject — this catches the node-scoped handle inheritance. 5. Only then accept `Q` as workload attestation. Steps 3 and 4 are the ones the naive verifier skips. Step 3 is cheap; step 4 requires a TPM2 `ReadPublic` + `PolicyGetDigest` round-trip and is the one operators omit under latency pressure. ## Operational Effect The practical consequence is that **warrant TTL is not a substitute for binding re-verification**. A 15-minute TTL on `W` did nothing to prevent the T+11 acceptance, because the warrant was still within TTL and the verifier had no reason to re-check the binding. The correct operational posture is: - **Re-verify binding on every quote presentation**, not just at warrant issuance. Cost: one `PolicyGetDigest` call, ~2–5 ms on a local TPM, ~15–40 ms over a network TPM proxy. - **Invalidate warrants on reschedule events.** The orchestrator must publish a reschedule signal that revokes any warrant whose `pcr10` no longer matches the live workload. Without this, TTL is the only backstop and it is too coarse. - **Log the extend log, not the PCR value.** Auditors replaying a transcript need the extend sequence to recompute; a cached PCR value is unreplayable and is exactly what hid the divergence for 40 minutes. The deeper lesson: hardware attestation shifts trust from "the key holder" to "the measured platform," but it does not automatically shift trust to "the measured workload." The gap between platform and workload is where reschedule, in-place upgrade, and handle inheritance live, and it is the gap an AAIF verifier must explicitly close or explicitly accept as a known residual risk. An instance that cannot distinguish platform liveness from workload liveness will accept a stale credential as a live identity, and the only signal will be a replay divergence discovered after the fact. ```python class AttestationBindingError(RuntimeError): """Raised when a hardware quote is validly signed but not bound to the warranted workload.""" pass def verify_workload_attestation(quote, warrant, tpm_proxy) -> None: # Step 3: recompute expected PCR from the warrant's extend log, # never trust a cached snapshot. expected_pcr = fold_extend(warrant.extend_log) if quote.pcr10 != expected_pcr: raise AttestationBindingError( f"PCR divergence: quote={quote.pcr10.hex()} " f"expected={expected_pcr.hex()} ak_id={warrant.ak_id}" ) # Step 4: the key handle must have been created under a policy # bound to the warranted PCR value. A node-scoped handle that # survived a reschedule will fail this check. policy_digest = tpm_proxy.policy_get_digest(warrant.ak_id) if policy_digest != expected_pcr: raise AttestationBindingError( f"AK {warrant.ak_id} handle policy {policy_digest.hex()} " f"does not bind warranted workload {expected_pcr.hex()}; " f"handle likely inherited across reschedule" ) # Only now is the quote evidence of workload identity. return None ```