Branch: refs/heads/master
  Home:   https://github.com/tianocore/edk2
  Commit: 2d4c76f783ee7eaab65b64f2f8c04f78394be0d1
      
https://github.com/tianocore/edk2/commit/2d4c76f783ee7eaab65b64f2f8c04f78394be0d1
  Author: Giri Mudusuru <gi...@apple.com>
  Date:   2023-05-12 (Fri, 12 May 2023)

  Changed paths:
    M MdePkg/Include/IndustryStandard/SmBios.h

  Log Message:
  -----------
  MdePkg/IndustryStandard: Add SMBIOS anchor string & length defines.

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3805

Add SMBIOS spec defined anchor strings & length defines.

 - '_SM_' chapter 5.2.1 SMBIOS 2.1 (32-bit) Entry Point
 - '_SM3_' chapter 5.2.2 SMBIOS 3.0 (64-bit) Entry Point

Changes from v1 to v2:
 - Replace non-ASCII characters

Cc: Michael D Kinney <michael.d.kin...@intel.com>
Cc: Liming Gao <gaolim...@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang....@intel.com>
Cc: Andrew Fish <af...@apple.com>
Signed-off-by: Giri Mudusuru <gi...@apple.com>
Reviewed-by: Liming Gao <gaolim...@byosoft.com.cn>


  Commit: 0b37723186ec1525b6caf14b0309fb0ed04084d7
      
https://github.com/tianocore/edk2/commit/0b37723186ec1525b6caf14b0309fb0ed04084d7
  Author: Giri Mudusuru <gi...@apple.com>
  Date:   2023-05-12 (Fri, 12 May 2023)

  Changed paths:
    M ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/PrintInfo.c
    M ShellPkg/Library/UefiShellDebug1CommandsLib/SmbiosView/SmbiosView.c

  Log Message:
  -----------
  ShellPkg/UefiShellDebug1CommandsLib: Replace hardcoded SMBIOS strings.

REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3805

Replace hardcoded SMBIOS Anchor string and size with defines.

Fix buffer overflow as described below.

Smbios64BitPrintEPSInfo () is coded like:
UINT8  Anchor[5];

MemToString (Anchor, SmbiosTable->AnchorString, 5);

But the definition of MemToString()
  Copy Length of Src buffer to Dest buffer,
  add a NULL termination to Dest buffer.

So Anchor needs to be +1 the size of the SMBIOS Anchor string `_SM3_`.

Changes from v1 to v2:
 - Replace doxygen style inline comments

Cc: Michael D Kinney <michael.d.kin...@intel.com>
Cc: Liming Gao <gaolim...@byosoft.com.cn>
Cc: Zhiguang Liu <zhiguang....@intel.com>
Cc: Andrew Fish <af...@apple.com>
Signed-off-by: Giri Mudusuru <gi...@apple.com>
Reviewed-by: Liming Gao <gaolim...@byosoft.com.cn>


Compare: https://github.com/tianocore/edk2/compare/c08a3a96fd19...0b37723186ec


_______________________________________________
edk2-commits mailing list
edk2-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to