edk2/MdeModulePkg/Library
Richard Lyu b1029265b1 MdeModulePkg/GptLib: Add host-based unit tests for malformed GPT input
Extend the GptLib host-based tests with negative cases that guard the
security hardening in PartitionValidGptTable(), PartitionCheckGptEntry()
and PartitionRestoreGptTable() against future regressions. These tests
exercise the shared parser, not the specific fix itself.

The new cases drive the parser with malformed GPT structures that an
attacker may present: bad signature/revision, header-size boundaries,
CRC corruption, MyLBA replay, zero/non-power-of-two entry sizes, LBA
multiplication overflow, out-of-range and overlapping entries, and
restore failure on write-protected media. The INF file header is
updated to note the added malformed coverage.

Signed-off-by: Richard Lyu <richard.lyu@suse.com>
2026-07-20 21:50:57 +00:00
..
ArmFfaConsoleDebugLib MdeModulePkg/Library: introduce ArmFfaConsoleDebugLib 2026-04-24 10:43:53 +00:00
ArmFfaLib MdePkg,MdeModulePkg: ArmFfaLib: Expand to include first 4 registers 2026-07-20 19:13:15 +00:00
AuthVariableLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseBmpSupportLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseHobLibNull MdeModulePkg: Remove ARM32 Support 2025-09-25 22:04:10 +00:00
BaseIpmiCommandLibNull MdeModulePkg/IpmiCommandLib: Add NULL instance library 2023-01-19 03:57:32 +00:00
BaseIpmiLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseMemoryAllocationLibNull MdeModulePkg: Remove ARM32 Support 2025-09-25 22:04:10 +00:00
BasePlatformHookLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseResetSystemLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseRngLibTimerLib MdePkg/Rng: Add GetRngGuid() to RngLib 2023-09-08 09:48:55 +00:00
BaseSerialPortLib16550 MdeModulePkg: Fix definition typos 2025-06-11 17:20:20 +00:00
BaseSortLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BaseSpiHcPlatformLibNull MdeModulePkg:BaseSpiHcPlatformLib: Adding NULL lib instance 2024-05-08 04:43:58 +00:00
BaseVariableFlashInfoLib MdeModulePkg/VariableFlashInfoLib: Add initial library 2022-05-19 06:11:20 +00:00
BootDiscoveryPolicyUiLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
BootLogoLib MdeModulePkg: Remove UGA support 2025-07-08 15:42:03 +00:00
BootMaintenanceManagerUiLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
BootManagerUiLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
BrotliCustomDecompressLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
CpuExceptionHandlerLibNull MdeModulePkg: CpuExceptionHandlerLibNull: Return Success On Null Func 2025-10-23 00:57:59 +00:00
CustomizedDisplayLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
DebugAgentLibNull MdeModulePkg/DebugAgentLibNull: Indicate SMM Debug Agent support or not 2023-12-26 07:18:26 +00:00
DeviceManagerUiLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
DisplayUpdateProgressLibGraphics MdeModulePkg: Fix imbalanced debug macros 2022-09-09 01:42:39 +00:00
DisplayUpdateProgressLibText MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeCapsuleLibFmp MdeModulePkg: Cleanup debug print readability 2026-05-06 10:43:05 +00:00
DxeCapsuleLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeCoreMemoryAllocationLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
DxeCorePerformanceLib MdeModulePkg: : revert EndofDxeEvent TPLs to TPL_NOTIFY for FPDT 2026-03-19 03:39:15 +00:00
DxeCrc32GuidedSectionExtractLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeDebugPrintErrorLevelLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxeFileExplorerProtocol MdeModulePkg: Remove DXE_SAL_DRIVER 2025-10-30 10:00:32 +00:00
DxeIpmiLibIpmiProtocol MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxePerformanceLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
DxePrintLibPrint2Protocol MdeModulePkg: Remove DXE_SAL_DRIVER 2025-10-30 10:00:32 +00:00
DxeReportStatusCodeLib MdeModulePkg/Library: Fix property typos 2026-01-26 08:44:12 +00:00
DxeResetSystemLib MdeModulePkg: HOST_APPLICATION IA32/X64 only 2023-04-10 05:59:02 +00:00
DxeSecurityManagementLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
FileExplorerLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
FmpAuthenticationLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
FrameBufferBltLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
GptLib MdeModulePkg/GptLib: Add host-based unit tests for malformed GPT input 2026-07-20 21:50:57 +00:00
HobPrintLib MdeModulePkg HobPrintLib: Also print EFI_HOB_TYPE_UNUSED type HOB 2026-02-28 03:56:45 +00:00
ImagePropertiesRecordLib MdeModulePkg/ImagePropertiesRecordLib: Reduce debug level 2024-06-26 12:40:30 +00:00
LockBoxNullLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
LzmaCustomDecompressLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
NonDiscoverableDeviceRegistrationLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
OemHookStatusCodeLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PciHostBridgeLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiCrc32GuidedSectionExtractLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiDebugLibDebugPpi MdeModulePkg/PeiDebugLibDebugPpi: Fix comma parsing in VaListToBaseList 2026-02-27 03:30:57 +00:00
PeiDebugPrintHobLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiDxeDebugLibReportStatusCode MdeModulePkg/PeiDxeDebugLibReportStatusCode: Fix comma parsing 2026-02-27 03:30:57 +00:00
PeiIpmiLibIpmiPpi MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiPerformanceLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiReportStatusCodeLib MdeModulePkg/Library: Fix property typos 2026-01-26 08:44:12 +00:00
PeiResetSystemLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PiDxeS3BootScriptLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
PiSmmCoreMemoryAllocationLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
PiSmmCoreSmmServicesTableLib MdeModulePkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:08 -07:00
PlatformBootManagerLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PlatformHookLibSerialPortPpi MdeModulePkg: Replace BSD License with BSD+Patent License 2019-04-09 10:58:08 -07:00
PlatformVarCleanupLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
ResetUtilityLib MdeModulePkg: Update code to be more C11 compliant by using __func__ 2023-04-10 14:19:57 +00:00
RuntimeDxeReportStatusCodeLib MdeModulePkg/Library: Fix property typos 2026-01-26 08:44:12 +00:00
RuntimeResetSystemLib MdeModulePkg/RuntimeResetSystemLib: Make global static 2024-07-12 02:03:12 +00:00
SmmCorePerformanceLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
SmmCorePlatformHookLibNull MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmIpmiLibSmmIpmiProtocol MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmLockBoxLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
SmmMemoryAllocationProfileLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SmmPerformanceLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
SmmReportStatusCodeLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
SmmSmiHandlerProfileLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
TdxMeasurementLibNull MdeModulePkg: Move TdxMeasurementLib from UefiCpuPkg 2025-03-18 17:57:40 +00:00
TpmMeasurementLibNull MdeModulePkg/TpmMeasurementLibNull: Allow broader linking 2025-06-05 10:05:24 +08:00
TraceHubDebugSysTLib MdeModulePkg: fix mdlint issues 2026-03-04 22:02:33 +00:00
UefiBootManagerLib MdeModulePkg: Update performance measurements to use new perf macros 2026-03-17 02:38:07 +00:00
UefiHiiLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
UefiHiiServicesLib MdeModulePkg: Remove DXE_SAL_DRIVER 2025-10-30 10:00:32 +00:00
UefiMemoryAllocationProfileLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
UefiSortLib MdeModulePkg: Apply uncrustify formatting to relevant files. 2023-10-27 00:50:49 +00:00
VarCheckHiiLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
VarCheckLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
VarCheckPcdLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
VarCheckPolicyLib MdeModulePkg: Replace include guards with #pragma once 2026-02-23 21:01:28 +00:00
VarCheckUefiLib MdeModulePkg/Library: Fix property typos 2026-01-26 08:44:12 +00:00
VariablePolicyHelperLib MdeModulePkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
VariablePolicyLib MdeModulePkg: fix mdlint issues 2026-03-04 22:02:33 +00:00