SecurityPkg: Measure Invoke EBS even in failure case

This patch measures the ExitBootServices invocation to the
TPM even in the case of ExitBootServices failing, per TCG
PC Client Platform Firmware Profile Version 1.06 Revision
52 Family 2.0 section 8.2.4(i).

Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com>
This commit is contained in:
Matthew Carlson 2020-06-19 20:49:33 +00:00 committed by mergify[bot]
parent baecba68a3
commit 96b90e150c
1 changed files with 11 additions and 0 deletions

View File

@ -2615,6 +2615,17 @@ OnExitBootServicesFailed (
{ {
EFI_STATUS Status; EFI_STATUS Status;
//
// Measure invocation of ExitBootServices,
//
Status = TcgMeasureAction (
5,
EFI_EXIT_BOOT_SERVICES_INVOCATION
);
if (EFI_ERROR (Status)) {
DEBUG ((DEBUG_ERROR, "%a not Measured. Error!\n", EFI_EXIT_BOOT_SERVICES_INVOCATION));
}
// //
// Measure Failure of ExitBootServices, // Measure Failure of ExitBootServices,
// //