Skip to content

Commit

Permalink
SecurityPkg: Add TCG_EfiSpecIDEventStruct_SPEC_ERRATA_TPM2_REV_106 check
Browse files Browse the repository at this point in the history
Signed-off-by: Wenxing Hou <[email protected]>
  • Loading branch information
Wenxing-hou authored and jyao1 committed Jan 26, 2024
1 parent 30c1e7d commit 8dffa20
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions SecurityPkg/DeviceSecurity/SpdmSecurityLib/SpdmSecurityLib.c
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,10 @@ SpdmDeviceAuthenticationAndMeasurement (
BOOLEAN IsValidCertChain;
BOOLEAN RootCertMatch;

if (PcdGet32 (PcdTcgPfpMeasurementRevision) < TCG_EfiSpecIDEventStruct_SPEC_ERRATA_TPM2_REV_106) {
return EFI_UNSUPPORTED;
}

SpdmDeviceContext = CreateSpdmDeviceContext (SpdmDeviceInfo, SecurityState);
if (SpdmDeviceContext == NULL) {
return EFI_UNSUPPORTED;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,6 @@
gEdkiiDeviceSignatureDatabaseGuid ## CONSUMES
gEfiCertX509Guid ## CONSUMES
gEfiDeviceSecuritySpdmUidGuid ## PRODUCES AND CONSUMES

[Pcd]
gEfiMdeModulePkgTokenSpaceGuid.PcdTcgPfpMeasurementRevision ## CONSUMES

0 comments on commit 8dffa20

Please sign in to comment.