Remote attestation of SEV-SNP confidential VMs using e-vTPMs

Vikram Narayanan, Cláudio Carvalho, Angelo Ruocco, Gheorghe Almási, James Bottomley, Mengmei Ye, Tobin Feldman-Fitzthum, Daniele Buono, Hubertus Franke, Anton BurtsevarXiv 2023 · OpenReview

Introduction

Confidential Computing relies on Trusted Execution Environments (TEEs) such as AMD SEV-SNP to protect Virtual Machine (VM) memory from unauthorized access by the cloud provider or hypervisor. However, ensuring the integrity of the software running within these environments requires Remote Attestation, typically facilitated by a Trusted Platform Module (TPM). In cloud settings, TPMs are virtualized (vTPMs) and managed by the hypervisor, creating a trust paradox: the user must trust the very entity they seek to exclude. Furthermore, existing vTPM solutions face challenges with complex state management and vulnerability to rollback attacks.

The SVSM-vTPM Architecture

To address these issues, researchers developed SVSM-vTPM, a virtual TPM that resides within the VM's hardware-encrypted boundary. This approach leverages AMD SEV-SNP’s Virtual Machine Privilege Levels (VMPLs) to provide internal isolation.

Architecture of SVSM-vTPM within an SEV-SNP Confidential VM, showing isolation between VMPL0 and VMPL1.

As shown in Figure 1, the vTPM operates at the most privileged level (VMPL0), while the Guest OS and firmware (OVMF) run at VMPL1. This hardware-enforced separation prevents the Guest OS from tampering with the vTPM's internal state or keys. The vTPM is integrated into the Secure VM Service Module (SVSM), which manages communication between the guest and the hardware security processor.

Design Principles: Statelessness and Trust

A defining characteristic of SVSM-vTPM is its ephemeral nature. Unlike traditional TPMs that persist state to non-volatile memory, SVSM-vTPM generates a new set of keys upon every boot. This "stateless" design eliminates the need for secure persistent storage on the host, thereby removing vectors for state-exfiltration and rollback attacks.

Comparison of SVSM-vTPM with existing vTPM solutions like SvTPM and CocoTPM.

The trust anchor for SVSM-vTPM is rooted in the AMD hardware. During the boot process, the hardware-signed SEV-SNP attestation report is used to certify the vTPM's public keys, creating an unbreakable link between the physical CPU and the virtual TPM's identity.

Performance and Security Evaluation

The evaluation of SVSM-vTPM demonstrated significant performance advantages over traditional host-based vTPMs (e.g., qemu-vTPM with swtpm). By keeping the vTPM within the VM's memory space, the system avoids slow host-side context switches and Unix socket communication.

Key performance metrics include:

  • PCR Reads: 5x lower latency (3.3μs vs 15.4μs).
  • TPM Quotes: 5x lower latency (10.2μs vs 49.5μs).
  • Key Creation: 3.5x lower latency for CREATEPRIMARY operations.

From a security perspective, SVSM-vTPM effectively mitigates "Fake vTPM" attacks. An attacker compromising the guest OS cannot spoof a valid hardware attestation report that corresponds to a malicious software TPM.

Limitations and Future Outlook

While SVSM-vTPM offers robust security and performance, it is currently tied to AMD SEV-SNP's VMPL feature. Future implementations for platforms like Intel TDX or ARM CCA would require similar privilege-separation mechanisms. Additionally, the ephemeral design places a high dependency on the hardware Random Number Generator (RNG) and requires users to manage long-term secrets (e.g., disk encryption keys) through a wrapping hierarchy.

Conclusion

SVSM-vTPM represents a significant advancement in confidential computing by moving the root-of-trust inside the VM boundary. By embracing statelessness, the architecture simplifies security management while delivering superior performance, providing a scalable path for trustless cloud environments.

Summary updated

BibTeX
@misc{narayanan2023remote,
  author = {Vikram Narayanan and Cláudio Carvalho and Angelo Ruocco and Gheorghe Almási and James Bottomley and Mengmei Ye and Tobin Feldman-Fitzthum and Daniele Buono and Hubertus Franke and Anton Burtsev},
  title = {{Remote attestation of SEV-SNP confidential VMs using e-vTPMs}},
  year = {2023},
  url = {https://openreview.net/forum?id=U0JvK3IMGU},
}
Figure