53 OUT UINT32 *OutputBufferSize,
54 OUT UINT32 *ScratchBufferSize,
55 OUT UINT16 *SectionAttribute
58 if (IS_SECTION2 (InputSection)) {
63 &gEfiCrc32GuidedSectionExtractionGuid,
67 return EFI_INVALID_PARAMETER;
74 *ScratchBufferSize = 0;
81 &gEfiCrc32GuidedSectionExtractionGuid,
85 return EFI_INVALID_PARAMETER;
92 *ScratchBufferSize = 0;
120 OUT VOID **OutputBuffer,
121 IN VOID *ScratchBuffer OPTIONAL,
122 OUT UINT32 *AuthenticationStatus
126 UINT32 SectionCrc32Checksum;
127 UINT32 Crc32Checksum;
128 UINT32 OutputBufferSize;
129 VOID *DummyInterface;
131 if (IS_SECTION2 (InputSection)) {
136 &gEfiCrc32GuidedSectionExtractionGuid,
140 return EFI_INVALID_PARAMETER;
154 *AuthenticationStatus = EFI_AUTH_STATUS_IMAGE_SIGNED;
160 &gEfiCrc32GuidedSectionExtractionGuid,
164 return EFI_INVALID_PARAMETER;
178 *AuthenticationStatus = EFI_AUTH_STATUS_IMAGE_SIGNED;
189 Status =
gBS->LocateProtocol (&gEfiSecurityPolicyProtocolGuid,
NULL, &DummyInterface);
190 if (!EFI_ERROR (Status)) {
199 Status =
gBS->CalculateCrc32 (*OutputBuffer, OutputBufferSize, &Crc32Checksum);
201 if (Crc32Checksum != SectionCrc32Checksum) {
205 *AuthenticationStatus |= EFI_AUTH_STATUS_TEST_FAILED;
211 *AuthenticationStatus |= EFI_AUTH_STATUS_NOT_TESTED;
235 &gEfiCrc32GuidedSectionExtractionGuid,
BOOLEAN EFIAPI CompareGuid(IN CONST GUID *Guid1, IN CONST GUID *Guid2)
#define SECTION_SIZE(SectionHeaderPtr)
#define EFI_AUTH_STATUS_PLATFORM_OVERRIDE
UINT32 CRC32Checksum
32bit CRC check sum
EFI_GUID_DEFINED_SECTION2 GuidedSectionHeader
EFI guided section header.
EFI_GUID_DEFINED_SECTION GuidedSectionHeader
EFI guided section header.
UINT32 CRC32Checksum
32bit CRC check sum