@@ -210,6 +210,49 @@ converted to shared on boot.
210210For coherent DMA allocation, the DMA buffer gets converted on the
211211allocation. Check force_dma_unencrypted() for details.
212212
213+ Attestation
214+ ===========
215+
216+ Attestation is used to verify the TDX guest trustworthiness to other
217+ entities before provisioning secrets to the guest. For example, a key
218+ server may want to use attestation to verify that the guest is the
219+ desired one before releasing the encryption keys to mount the encrypted
220+ rootfs or a secondary drive.
221+
222+ The TDX module records the state of the TDX guest in various stages of
223+ the guest boot process using the build time measurement register (MRTD)
224+ and runtime measurement registers (RTMR). Measurements related to the
225+ guest initial configuration and firmware image are recorded in the MRTD
226+ register. Measurements related to initial state, kernel image, firmware
227+ image, command line options, initrd, ACPI tables, etc are recorded in
228+ RTMR registers. For more details, as an example, please refer to TDX
229+ Virtual Firmware design specification, section titled "TD Measurement".
230+ At TDX guest runtime, the attestation process is used to attest to these
231+ measurements.
232+
233+ The attestation process consists of two steps: TDREPORT generation and
234+ Quote generation.
235+
236+ TDX guest uses TDCALL[TDG.MR.REPORT] to get the TDREPORT (TDREPORT_STRUCT)
237+ from the TDX module. TDREPORT is a fixed-size data structure generated by
238+ the TDX module which contains guest-specific information (such as build
239+ and boot measurements), platform security version, and the MAC to protect
240+ the integrity of the TDREPORT. A user-provided 64-Byte REPORTDATA is used
241+ as input and included in the TDREPORT. Typically it can be some nonce
242+ provided by attestation service so the TDREPORT can be verified uniquely.
243+ More details about the TDREPORT can be found in Intel TDX Module
244+ specification, section titled "TDG.MR.REPORT Leaf".
245+
246+ After getting the TDREPORT, the second step of the attestation process
247+ is to send it to the Quoting Enclave (QE) to generate the Quote. TDREPORT
248+ by design can only be verified on the local platform as the MAC key is
249+ bound to the platform. To support remote verification of the TDREPORT,
250+ TDX leverages Intel SGX Quoting Enclave to verify the TDREPORT locally
251+ and convert it to a remotely verifiable Quote. Method of sending TDREPORT
252+ to QE is implementation specific. Attestation software can choose
253+ whatever communication channel available (i.e. vsock or TCP/IP) to
254+ send the TDREPORT to QE and receive the Quote.
255+
213256References
214257==========
215258
0 commit comments