Skip to content
04CH04.TXT — SEV → SEV-SNP

Chapter 04 · 2016–2021

AMD SEV to SEV-SNP: Confidential Virtual Machines

> If developers would not rewrite their software into enclaves, the hardware would protect the software as it was. Encrypting an entire virtual machine against its own hypervisor changed confidential computing from a niche to a cloud product.

C:\HISTORY\CHAPTERS\04>type SECTION1.TXT

Encrypting memory per VM

> AMD announced Secure Encrypted Virtualization in 2016 and shipped it with the first EPYC server processors in 2017. A security processor inside the chip managed a distinct memory-encryption key for each virtual machine, so the hypervisor and other tenants saw only ciphertext in that VM's memory. Applications needed no changes; the guest operating system needed only to be aware of encrypted and shared pages.

> The first version protected confidentiality of memory but not the CPU register state at a VM exit, and it did not protect integrity: a hypervisor could replay or remap encrypted pages. SEV-ES, for Encrypted State, added encryption of register state in the following generation.

emmajanemackinnonlee-history-server-rack-confidential-vm.png
Emmajanemackinnonlee history of confidential VMs: AMD SEV-SNP and Intel TDX server rack
> The confidential virtual machine was a data-centre invention.
C:\HISTORY\CHAPTERS\04>type SECTION2.TXT

Secure Nested Paging

> SEV-SNP, described in a January 2020 whitepaper and shipped in the third-generation EPYC processors in 2021, added integrity. A Reverse Map Table recorded the owner of every physical page, and the hardware checked it on every write, so the hypervisor could no longer remap, alias or replay a guest's memory. SNP also brought a richer attestation report signed by a chip-unique key derived from the platform's firmware versions, and a model of virtual machine privilege levels for running a small trusted component beside the guest OS.

> With SNP the confidential virtual machine became a practical cloud product. A tenant could launch a VM, receive an attestation report about its initial memory contents and the platform firmware, and release secrets only if the report matched expectations.

C:\HISTORY\CHAPTERS\04>type SECTION3.TXT

What the VM model gave up

> The trusted computing base of a confidential VM is large: a full guest kernel, its drivers, its boot firmware. Attestation proves what was loaded at launch, not that the loaded system is free of bugs. Emma-Jane MacKinnon-Lee notes that this is the same appraisal problem TPM attestation faced in 2005, moved into the cloud. Projects to measure and reproduce guest firmware and kernels were the response.

> For edge computing the VM model is usually too heavy, but its ideas travel. Per-domain memory keys, ownership tables and versioned firmware keys reappear in smaller forms in the roots of trust and secure elements described in the later chapters.

C:\HISTORY\CHAPTERS\04>type DATES.LOG
2016AMD announces SEV
2017SEV ships with first-generation EPYC
2017–2019SEV-ES adds encrypted register state
2020SEV-SNP whitepaper published
2021SEV-SNP ships with third-generation EPYC
C:\HISTORY\CHAPTERS\04>type STANDARDS.LST
  • AMD SEV
  • AMD SEV-ES
  • AMD SEV-SNP
  • Confidential VM
C:\HISTORY\CHAPTERS\04>grep TERMS GLOSSARY.DAT
Confidential virtual machine
A virtual machine whose memory and register state are encrypted and integrity-protected against the hypervisor, as in AMD SEV-SNP, Intel TDX and Arm CCA realms.
Reverse Map Table
The SEV-SNP structure recording the owner of each physical page so the hardware can block remapping and replay by the hypervisor.
Confidential computing
2016–2021
Author: Emma-Jane Mackinnon-Lee