Repository navigation
Conversation
GCE's TDVF measures etc/table-loader, etc/vanadium/acpi/rsdp and etc/vanadium/acpi/tables into RTMR0. Captures from c3-standard TDX VMs show they depend only on the vCPU count and memory size: data disks, local SSDs and the zone leave them unchanged. Generate them in pure Rust so a verifier can check those RTMR0 events instead of trusting whatever ACPI the host supplied. Every table is built from structure (a small AML encoder, since GCE uses fixed-width integers where acpi_tables would pick the shortest form); there are no binary templates. The table-loader also carries GCE's vendor commands that point the firmware at the DSDT integers it overwrites with the PCI windows after measurement. The output matches the event-log digests of c3-standard-4, -8 and -22 byte for byte. Larger multi-socket shapes have not been captured. Signed-off-by: Kevin Wang <wy721@qq.com>
Version 2 of measurement.gcp.cbor records the RTMR1 and RTMR2 values GCE's TDVF produces when it boots the image, computed at build time from the UKI and the GPT of disk.raw. For such images the verifier now also checks: - MRTD is one of the known GCE TDVF builds; - RTMR0 replays from the attested event log, and its TD HOB, CFV and ACPI table events match values recomputed by the verifier (ACPI tables from gcp-acpi); - RTMR1 and RTMR2 match the image measurement. The existing vTPM checks are unchanged. GCP attestations now keep every RTMR0 event digest when stripped so the verifier can replay RTMR0. Signed-off-by: Kevin Wang <wy721@qq.com>
kvinwang
force-pushed
the
feat/gcp-acpi
branch
from
December 2, 2026 09:41
3a480bf to
b72ca45
Compare
Captured c3-standard-44, -88, -176 and a3-highgpu-1g (one H100) TDX VMs and extended the ACPI and TD HOB model to match them byte for byte: - NUMA: 44 vCPUs per node, two nodes per socket. Sockets start at the next power-of-two APIC ID, the SSDT names CPUs by APIC ID, CPON marks the gaps, SRAT and the TD HOB give each node its own RAM range, and a SLIT is added on multi-node shapes. - GPU: a second host bridge PR01 owns buses 1-255, PCI hotplug and the AC adapter are off, and low RAM ends at 2 GiB. - a3-highgpu hosts run the 2026-06-26 TDVF build, now in the allowlist. The verifier takes the shape from the VM config's cpu_count, memory_size and num_gpus when present, and otherwise tries every shape GCE offers for TDX. Either way the regenerated tables must match the measured ones. Signed-off-by: Kevin Wang <wy721@qq.com>
dstack-cloud now writes cpu_count, memory_size and num_gpus of the GCE machine type into the GCP vm_config, and the verifier requires them for v2 images instead of trying a built-in list of GCE shapes. The shape is only trusted as far as it reproduces the measured ACPI tables and TD HOB. Signed-off-by: Kevin Wang <wy721@qq.com>
The verifier derived the node count from a 44-vCPUs-per-node rule while vm_config.numa_nodes stayed empty, which by its own definition means one node. dstack-cloud now writes numa_nodes for multi-node GCE machine types (gcloud does not report it, so the rule moves there), and the verifier reads it like the other shape fields. Signed-off-by: Kevin Wang <wy721@qq.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Checks MRTD and RTMR0–2 of GCP TDX boots in addition to the existing vTPM checks, so trust no longer rests on the vTPM alone.
crates/gcp-acpi: pure Rust generator for the three ACPI fw_cfg blobs GCE's TDVF measures into RTMR0 (etc/table-loader,etc/vanadium/acpi/rsdp,etc/vanadium/acpi/tables).Verification (
dstack_mr::gcp::verify_gcp_tdx_boot), enforced whenmeasurement.gcp.cboris version 2:.fdimages, which carry Google-signed endorsements.cpu_count,memory_size,num_gpusandnuma_nodesin the VM config, whichdstack-cloudnow fills in from the GCE machine type. Only UEFI variable events are not reproduced; Secure Boot and boot-device selection are pinned by RTMR1.dstack-mr gcp-measurement-cborcomputes at build time from the UKI and the GPT ofdisk.raw.v1 images still verify with the vTPM checks only.
Tested against quotes and CCEL from dstack 0.6.7 on c3-standard-4, and from Ubuntu on c3-standard-8, -22, -44, -88, -176 and a3-highgpu-1g.