OvmfPkg/IntelTdx: Measure Td HobList and Configuration FV

RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3853

TdHobList and Configuration FV are external data provided by Host VMM.
These are not trusted in Td guest. So they should be validated , measured
and extended to Td RTMR registers. In the meantime 2 EFI_CC_EVENT_HOB are
created. These 2 GUIDed HOBs carry the hash value of TdHobList and
Configuration FV. In DXE phase EFI_CC_EVENT can be created based on these
2 GUIDed HOBs.

Cc: Ard Biesheuvel <ardb+tianocore@kernel.org>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>
Cc: Brijesh Singh <brijesh.singh@amd.com>
Cc: Erdem Aktas <erdemaktas@google.com>
Cc: James Bottomley <jejb@linux.ibm.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Tom Lendacky <thomas.lendacky@amd.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
Signed-off-by: Min Xu <min.m.xu@intel.com>
This commit is contained in:
Min Xu
2022-05-16 15:42:19 +08:00
committed by mergify[bot]
parent a708536dce
commit 4b0a622635
5 changed files with 221 additions and 2 deletions

View File

@@ -52,4 +52,21 @@ EFIAPI
ConstructSecHobList (
);
/**
Check the integrity of CFV data.
@param[in] TdxCfvBase - A pointer to CFV header
@param[in] TdxCfvSize - CFV data size
@retval TRUE - The CFV data is valid.
@retval FALSE - The CFV data is invalid.
**/
BOOLEAN
EFIAPI
TdxValidateCfv (
IN UINT8 *TdxCfvBase,
IN UINT32 TdxCfvSize
);
#endif