Acidanthera UEFI Development Kit based on EDK II edk2-stable202311
Go to file
Long Qin cf8197a39d CryptoPkg/BaseCryptLib: Fix buffer overflow issue in realloc wrapper
There is one long-standing problem in CRT realloc wrapper, which will
cause the obvious buffer overflow issue when re-allocating one bigger
memory block:
    void *realloc (void *ptr, size_t size)
    {
      //
      // BUG: hardcode OldSize == size! We have no any knowledge about
      // memory size of original pointer ptr.
      //
      return ReallocatePool ((UINTN) size, (UINTN) size, ptr);
    }
This patch introduces one extra header to record the memory buffer size
information when allocating memory block from malloc routine, and re-wrap
the realloc() and free() routines to remove this BUG.

Cc: Laszlo Ersek <lersek@redhat.com>
Cc: Ting Ye <ting.ye@intel.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Qin Long <qin.long@intel.com>
Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
Validated-by: Jian J Wang <jian.j.wang@intel.com>
2017-11-06 14:50:17 +08:00
AppPkg AppPkg/WebServer: Fix build failure. 2017-09-14 08:55:09 +08:00
ArmPkg ArmPkg/ArmSvcLib: Add ArmSvcLib implementation. 2017-10-06 22:35:41 +01:00
ArmPlatformPkg ArmPlatformPkg/PlatformPeim: allow PlatformPeiLib to set the boot mode 2017-11-05 16:19:00 +00:00
ArmVirtPkg ArmVirtPkg ArmVirtDxeHobLib: Implement BuildFv3Hob 2017-10-10 20:54:48 +08:00
BaseTools BaseTools: parse map file generated by Xcode on Mac 2017-11-03 14:30:49 +08:00
BeagleBoardPkg BeagleBoardPkg: switch to generic non-coherent DmaLib 2017-08-30 14:13:58 +01:00
Conf EDK II: Add .gitignore 2014-10-14 16:08:15 +00:00
CorebootModulePkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
CorebootPayloadPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
CryptoPkg CryptoPkg/BaseCryptLib: Fix buffer overflow issue in realloc wrapper 2017-11-06 14:50:17 +08:00
DuetPkg DuetPkg: Fix Xcode 9 Beta treating 32-bit left shift as undefined 2017-08-11 08:44:54 +08:00
EdkCompatibilityPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
EdkShellBinPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
EdkShellPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
EmbeddedPkg EmbeddedPkg: introduce GPIO PPI 2017-11-05 16:18:49 +00:00
EmulatorPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
FatBinPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
FatPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
IntelFrameworkModulePkg IntelFrameworkModule/LegacyBios: Avoid explicit comparison for BOOLEAN 2017-10-24 09:14:17 +08:00
IntelFrameworkPkg IntelFrameworkPkg PeiHobLibFramework: Implement BuildFv3Hob 2017-10-10 20:54:37 +08:00
IntelFsp2Pkg IntelFsp2Pkg: Update Section Name in INF files 2017-10-10 18:10:23 +08:00
IntelFsp2WrapperPkg IntelFsp2WrapperPkg: Update Protocol/Guid usage in INF files 2017-10-10 18:10:24 +08:00
IntelFspPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
IntelFspWrapperPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
IntelSiliconPkg IntelSiliconPkg IntelVTdDxe: Use ACPI table event to get DMAR table 2017-11-06 10:08:48 +08:00
MdeModulePkg MdeModulePkg: Update PeiCore consumes PCD to get the init value in temp stack 2017-11-03 17:45:47 +08:00
MdePkg MdePkg: Deprecate EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS 2017-11-01 22:25:18 +08:00
NetworkPkg NetworkPkg/IScsiDxe: Add check to avoid use NULL pointer 2017-10-30 08:51:59 +08:00
Nt32Pkg Nt32Pkg: Update SecMain consumes PCD to get the init value in temp stack 2017-11-03 17:45:51 +08:00
Omap35xxPkg Omap35xxPkg: switch to EmbeddedPkg's NonCoherentDmaLib 2017-08-30 14:13:47 +01:00
OptionRomPkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
OvmfPkg OvmfPkg: fix dynamic default for oprom verification policy PCD without SB 2017-10-19 10:41:09 +02:00
PcAtChipsetPkg PcAtChipsetPkg: Update GUID usage in PcRtc INF to match the source code 2017-10-10 18:10:18 +08:00
PerformancePkg PerformancePkg DP: Init CustomCumulativeData.MinDur 2017-08-14 16:55:44 +08:00
QuarkPlatformPkg QuarkPlatformPkg/Readme.md: Bring Readme.md up to date 2017-08-10 09:44:24 -07:00
QuarkSocPkg QuarkSocPkg/QNCSmmDispatcher: Fix use after free issue #2 2017-08-16 19:42:17 -07:00
SecurityPkg SecurityPkg: Remove Counter Based AuthVariable support 2017-11-01 22:24:59 +08:00
ShellBinPkg ShellBinPkg: AARCH64/ARM Shell binary update. 2017-08-31 15:41:59 +01:00
ShellPkg ShellPkg/hexeditor: Use CpuIo for memory access 2017-11-02 08:40:33 +08:00
SignedCapsulePkg SignedCapsulePkg: Update Guid usage in INF file to match source code logic 2017-10-10 18:10:21 +08:00
SourceLevelDebugPkg SourceLevelDebugPkg: Update SmmDebugAgentLib to restore APIC timer 2017-10-16 11:23:16 +08:00
StdLib edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
StdLibPrivateInternalFiles edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
UefiCpuPkg UefiCpuPkg/MpInitLib:Make function comments align with function 2017-11-02 09:24:05 +08:00
UnixPkg UnixPkg: Remove UnixPkg files (It is replaced by EmulatorPkg) 2013-07-29 21:09:55 +00:00
Vlv2DeviceRefCodePkg edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
Vlv2TbltDevicePkg Vlv2TbltDevicePkg: Remove reference deprecated macro. 2017-08-07 15:28:13 +08:00
.gitignore edk2: Add .DS_Store to .gitignore for macOS 2017-05-19 15:14:34 -07:00
BuildNotes2.txt BaseTools: Updated BuildNotes URLs 2016-03-25 09:46:44 +08:00
Contributions.txt edk2: Fix typo in Contributions.txt 2017-08-16 17:50:44 +08:00
Edk2Setup.bat Edk2Setup.bat: Fix build errors from VS tools PREFIX ENV missing 2016-11-05 09:10:58 +08:00
License.txt edk2: Move License.txt file to root 2017-08-03 11:02:17 -07:00
Maintainers.txt Add one maintainer to CorebootModulePkg and CorebootPayloadPkg 2017-11-02 10:17:54 +08:00
Readme.md edk2: Add Readme.md to root of edk2 repository 2017-08-03 11:02:25 -07:00
edksetup.bat BaseTools: suppress usage instructions with rebuild options 2017-07-04 10:16:13 +08:00
edksetup.sh BaseTools/edksetup.sh: fix invalid test for current working directory 2017-08-10 12:54:58 +08:00

Readme.md

EDK II Project

A modern, feature-rich, cross-platform firmware development environment for the UEFI and PI specifications from www.uefi.org.

Contributions to the EDK II open source project are covered by the TianoCore Contribution Agreement 1.1

The majority of the content in the EDK II open source project uses a BSD 2-Clause License. The EDK II open source project contains the following components that are covered by additional licenses:

The EDK II Project is composed of packages. The maintainers for each package are listed in Maintainers.txt.

Resources