From 9bc250419d5125b657986ff43bc4ba9782f58571 Mon Sep 17 00:00:00 2001 From: "Gao, Liming" Date: Mon, 11 Aug 2014 05:40:40 +0000 Subject: [PATCH] MdeModulePkg: DxeCore If GUIDED section has AUTH attribute only, DxeCore may wrongly set its AuthenticationStatus to 0 when its matched GUIDED extraction handler is not installed and Auth data is not verified. For this case, the return AuthenticationStatus should be EFI_AUTH_STATUS_NOT_TESTED. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gao, Liming Reviewed-by: Kinney, Michael D Reviewed-by: Yao, Jiewen git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15781 6f19259b-4bc3-4df7-8a09-765794883524 --- .../Core/Dxe/SectionExtraction/CoreSectionExtraction.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c b/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c index e5e3926e3a..981744c4d3 100644 --- a/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c +++ b/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c @@ -903,6 +903,10 @@ CreateChildNode ( // AuthenticationStatus = Stream->AuthenticationStatus; + if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_AUTH_STATUS_VALID) == EFI_GUIDED_SECTION_AUTH_STATUS_VALID) { + AuthenticationStatus |= EFI_AUTH_STATUS_IMAGE_SIGNED | EFI_AUTH_STATUS_NOT_TESTED; + } + if (IS_SECTION2 (GuidedHeader)) { Status = OpenSectionStreamEx ( SECTION2_SIZE (GuidedHeader) - ((EFI_GUID_DEFINED_SECTION2 *) GuidedHeader)->DataOffset, -- 2.39.2