Re: [edk2-devel] [PATCH 14/19] Silicon/NXP/LS1043A: Replce SocLib

2020-02-13 Thread Pankaj Bansal
> -Original Message- > From: Leif Lindholm > Sent: Thursday, February 13, 2020 4:20 AM > To: Pankaj Bansal > Cc: Meenakshi Aggarwal ; Michael D Kinney > ; Varun Sethi ; > devel@edk2.groups.io > Subject: Re: [PATCH 14/19] Silicon/NXP/LS1043A: Replce SocLib > > On Wed, Feb 12, 2020 at

Re: [edk2-devel] [PATCH v2 0/3] Ovmf: enable TPM 1.2

2020-02-13 Thread Yao, Jiewen
Hi Lureau I don’t think we should expose the TPM Interface type via TpmCommandLib. That is the TPM device implementation. The TPM device might use TIS/FIFO/CRB, but there might be also other type such as I2C, or fTPM implementation type. To distinguish TPM2.0 or TPM1.2, the standard way is to

Re: [edk2-devel] [PATCH 3/3] SecurityPkg: Issues reported by ECC in EDK2.

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: devel@edk2.groups.io On Behalf Of GuoMinJ > Sent: Thursday, February 13, 2020 4:34 PM > To: devel@edk2.groups.io > Cc: GuoMinJ > Subject: [edk2-devel] [PATCH 3/3] SecurityPkg: Issues reported by ECC in EDK2. > >

Re: [edk2-devel] [PATCH v2 0/3] UefiCpuPkg/CpuFeature: Introduce First to indicate 1st unit.

2020-02-13 Thread Ni, Ray
Laszlo, I forgot to add you to CC list. Do you have any comments on the patch set? Thanks, Ray > -Original Message- > From: Dong, Eric > Sent: Thursday, February 13, 2020 4:04 PM > To: devel@edk2.groups.io; Ni, Ray > Subject: RE: [edk2-devel] [PATCH v2 0/3] UefiCpuPkg/CpuFeature:

Re: [edk2-devel] [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsCertHashFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Comment below: 1) I think the function name - IsCertHashFoundInDatabase() and the implementation { DbxList = SignatureList; DbxSize = SignatureListSize; } bring some confusion to me. If this is a *generic* database search function, I recommend we use a generic name - not use

Re: [edk2-devel] [PATCH v2 1/1] MdePkg: Add PCCT table signature definition

2020-02-13 Thread Liming Gao
Push @a67efa3b22113cc9b52f8e56e50466d6da0ab11e > -Original Message- > From: devel@edk2.groups.io On Behalf Of Liming Gao > Sent: Thursday, February 13, 2020 8:59 AM > To: Krzysztof Koch ; devel@edk2.groups.io > Cc: Kinney, Michael D ; matteo.carl...@arm.com; > sami.muja...@arm.com;

Re: [edk2-devel] [PATCH 7/9] SecurityPkg/DxeImageVerificationLib: tighten default result of IsForbiddenByDbx()(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:20 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > ; Laszlo Ersek > Subject: [PATCH 7/9] SecurityPkg/DxeImageVerificationLib: tighten default > result of

Re: [edk2-devel] [PATCH 8/9] SecurityPkg/DxeImageVerificationLib: plug Data leak in IsForbiddenByDbx()(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:20 PM > To: devel@edk2.groups.io > Cc: Laszlo Ersek ; Yao, Jiewen ; > Zhang, Chao B > Subject: [PATCH 8/9] SecurityPkg/DxeImageVerificationLib: plug Data leak in >

Re: [edk2-devel] [PATCH 9/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsSignatureFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:20 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH 9/9] SecurityPkg/DxeImageVerificationLib: Differentiate error > and search result in

[edk2-devel] [PATCH v2 2/3] SecurityPkg: export Tpm12GetPtpInterfaceType()

2020-02-13 Thread marcandre . lureau
From: Marc-André Lureau Signed-off-by: Marc-André Lureau --- SecurityPkg/Include/Library/Tpm12DeviceLib.h| 13 + .../Library/Tpm12DeviceLibDTpm/Tpm12Tis.c | 17 ++--- 2 files changed, 23 insertions(+), 7 deletions(-) diff --git

[edk2-devel] [PATCH v2 3/3] Ovmf: enable TPM 1.2 support

2020-02-13 Thread marcandre . lureau
From: Marc-André Lureau Enable TcgPei & TcgDxe modules to initialize a TPM 1.2 device and measure boot environment. Tpm12RequestUseTpm() returns success on any TPM interface, including FIFO & CRB which are TPM 2.0. Check the actual interface with Tpm12GetPtpInterfaceType(), and only detect 1.2

[edk2-devel] [PATCH v2 1/3] Ovmf: rename TPM2 config prefix to TPM

2020-02-13 Thread marcandre . lureau
From: Marc-André Lureau A following patch is going to use the same configuration for TPM1.2 and TPM2.0, and it's simpler to support both than variable configurations. Signed-off-by: Marc-André Lureau --- OvmfPkg/OvmfPkgIa32.dsc| 24 OvmfPkg/OvmfPkgIa32.fdf| 8

[edk2-devel] [PATCH 1/1] NetworkPkg/ArpDxe: Recycle invalid ARP packets(CVE-2019-14559).

2020-02-13 Thread Armour, Nicholas
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2031 This patch triggers the RecycleEvent for invalid ARP packets. Prior to this, we would just ignore invalid ARP packets, and never free them. Cc: Jiaxin Wu Cc: Maciej Rabeda Cc: Siyuan Fu Signed-off-by: Nicholas Armour ---

[edk2-devel] [PATCH v2 0/3] Ovmf: enable TPM 1.2

2020-02-13 Thread marcandre . lureau
From: Marc-André Lureau Hi, The following patches add basic TPM 1.2 support for Ovmf/QEMU. I tested successfully Win10 with TIS/TPM 1.2 & CRB/TPM 2.0 passthrough, and emulated CRB/TPM 2.0. (fwiw, I haven't tried to enable TPM_CONFIG_ENABLE) Marc-André Lureau (3): Ovmf: rename TPM2 config

Re: [edk2-devel] [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsCertHashFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
Jiewen, Thanks for the comments. 1) You're right. IsCertHashFoundInDatabase is quite general and cause confusions between db and dbx situation. Since it's not newly introduced in this patch series, do you think it's ok to fix it in separate patch series later? Or do you prefer fix it in this

Re: [edk2-devel] [edk2-platforms] [PATCH v2 3/5] Platform/ARM/SgiPkg: Add MultiChipMode to Platform Descriptor

2020-02-13 Thread Leif Lindholm
On Wed, Feb 12, 2020 at 18:59:25 +0530, Vijayenthiran Subramaniam wrote: > The 'system-id' node of HW_CONFIG device tree has been updated to have > a new property 'multi-chip-mode' which holds the information about the > multi-chip-mode support. To adapt to this change, add 'MultiChipMode' >

Re: [edk2-devel] [edk2-platforms] [PATCH v2 0/5] Platform/ARM/SgiPkg: Add support for RD-N1-Edge-Dual platform

2020-02-13 Thread Leif Lindholm
On the whole, looks good. If you can resubmit v3 versions of patches 2-3 only based on feedback, that would suffice. On a separate note: Could someone in ARM take an action item to go and figure out who should be default reviewer for the various ARM ltd platforms (virtual or not), and submit a

Re: [edk2-devel] [PATCH 1/9] SecurityPkg/DxeImageVerificationLib: Fix memory leaks(CVE-2019-14575)

2020-02-13 Thread Philippe Mathieu-Daudé
On 2/6/20 3:19 PM, Wang, Jian J wrote: REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 Pointer HashCtx used in IsCertHashFoundInDatabase() is not freed inside the while-loop, if it will run more than once. By extracting part of the code from the big while() statement into a new

Re: [edk2-devel] [PATCH v2 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Wang, Jian J
Thanks for the patch. Two comments below. > -Original Message- > From: Zurcher, Christopher J > Sent: Thursday, February 13, 2020 11:34 AM > To: devel@edk2.groups.io > Cc: Wang, Jian J ; Lu, XiaoyuX > Subject: [PATCH v2 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag > from

Re: [edk2-devel] [edk2-platforms] [PATCH v2 1/5] Platform/ARM/SgiPkg: Disable use of deprecated APIs

2020-02-13 Thread Leif Lindholm
On Wed, Feb 12, 2020 at 18:59:23 +0530, Vijayenthiran Subramaniam wrote: > Add the `DISABLE_NEW_DEPRECATED_INTERFACES` build option in DSC file to > make sure that the deprecated APIs are not used SgiPkg. > > Signed-off-by: Vijayenthiran Subramaniam Reviewed-by: Leif Lindholm > --- >

Re: [edk2-devel] [PATCH 8/9] SecurityPkg/DxeImageVerificationLib: plug Data leak in IsForbiddenByDbx()(CVE-2019-14575)

2020-02-13 Thread Philippe Mathieu-Daudé
On 2/6/20 3:19 PM, Wang, Jian J wrote: From: Laszlo Ersek REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 What a painful review... If the second GetVariable() call for "dbx" fails, in IsForbiddenByDbx(), we have to free Data. Jump to "Done" for that. Cc: Jiewen Yao Cc: Chao

Re: [edk2-devel] [edk2-platforms] [PATCH v2 2/5] Platform/ARM/SgiPkg: Use lookup table to install ACPI table

2020-02-13 Thread Leif Lindholm
On Wed, Feb 12, 2020 at 18:59:24 +0530, Vijayenthiran Subramaniam wrote: > Use lookup table to identify the platform and install corresponding ACPI > tables. As the number of supported platforms grow, the existing platform > identification using if..else does not scale well. > > Signed-off-by:

Re: [edk2-devel] [edk2-platforms] [PATCH v2 4/5] Platform/ARM/Sgi: Add ACPI tables for dual-chip RD-N1-Edge platform

2020-02-13 Thread Leif Lindholm
On Wed, Feb 12, 2020 at 18:59:26 +0530, Vijayenthiran Subramaniam wrote: > RD-N1-Edge supports a dual-chip configuration in which two RD-N1-Edge > platforms are connected through high speed CCIX link. In this dual-chip > configuration, the CPU and core GIC Redistributors count are doubled. > Add

Re: [edk2-devel] [edk2-platforms] [PATCH v2 5/5] Platform/ARM/Sgi: Add initial support for RD-N1-Edge-Dual platform

2020-02-13 Thread Leif Lindholm
On Wed, Feb 12, 2020 at 18:59:27 +0530, Vijayenthiran Subramaniam wrote: > For RD-N1-Edge platforms, use multi-chip-mode information from the > SGI platform descriptor HOB to pick the correct ACPI table to be > installed. > > Signed-off-by: Vijayenthiran Subramaniam Reviewed-by: Leif Lindholm

Re: [edk2-devel] [PATCH v2 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Zurcher, Christopher J
> -Original Message- > From: Wang, Jian J > Sent: Thursday, February 13, 2020 07:19 > To: Zurcher, Christopher J ; > devel@edk2.groups.io > Cc: Lu, XiaoyuX > Subject: RE: [PATCH v2 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" > flag from OpenSSL build > > Thanks for the patch. Two

Re: [edk2-devel] [edk2-platforms] [PATCH 4/4] WhiskeylakeOpenBoardPkg/UpXtreme: Add DSC and build files

2020-02-13 Thread Agyeman, Prince
Thanks Chasel, I have updated the readme.md in my v2 patch set and the BZ with the current status Prince -Original Message- From: Chiu, Chasel Sent: Thursday, February 13, 2020 12:22 AM To: Agyeman, Prince ; devel@edk2.groups.io Cc: Desimone, Nathaniel L Subject: RE: [edk2-platforms]

[edk2-devel] [edk2-platforms] [PATCH v2 0/4] Add Initial Support for UP Xtreme

2020-02-13 Thread Agyeman, Prince
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2191 This patch series add the initial Up Xtreme board support to the WhiskeylakeOpenBoardPkg V2 Changes: - Updated Readme.md to reflect the Current Status Current Status: 1. Basic boot to windows 10 (Home) and Ubuntu 18.04 from NVMe

[edk2-devel] [edk2-platforms] [PATCH v2 4/4] WhiskeylakeOpenBoardPkg/UpXtreme: Add DSC and build files

2020-02-13 Thread Agyeman, Prince
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2191 Adds the DSC and build files necessary to build the UpXtreme board instance. Key files = * build_config.cfg - Board-specific build configuration file. * OpenBoardPkg.dsc - The UpXtreme board description file. * OpenBoardPkgPcd.dsc -

[edk2-devel] [edk2-platforms] [PATCH v2 2/4] WhiskeylakeOpenBoardPkg: Add UpXtreme board ID

2020-02-13 Thread Agyeman, Prince
REF:https://bugzilla.tianocore.org/show_bug.cgi?id=2191 Co-authored-by: Michael Kubacki Cc: Chasel Chiu Cc: Nate DeSimone Signed-off-by: Prince Agyeman --- .../Intel/WhiskeylakeOpenBoardPkg/Include/PlatformBoardId.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git

[edk2-devel] [RFC PATCH 0/1] MdeModulePkg/PiDxeS3BootScriptLib: Use SafeIntLib to avoid truncation

2020-02-13 Thread Philippe Mathieu-Daudé
Commit 322ac05f8bbc added truncation checks to fix CVE-2019-14563. I found the 'a * b > d - c' reverse notation not obvious to review, and suggested to write 'a * b + c > d'. Laszlo explained me this is the EDK2 standard pattern to check against each overflow, but pointed out the SafeIntLib which

[edk2-devel] [RFC PATCH 1/1] MdeModulePkg/PiDxeS3BootScriptLib: Use SafeIntLib to avoid truncation

2020-02-13 Thread Philippe Mathieu-Daudé
Math expressions written in terms of SafeIntLib function calls are easily readable, making review trivial. Convert the truncation checks added by commit 322ac05f8 to SafeIntLib calls. Cc: Jian J Wang Cc: Hao A Wu Cc: Eric Dong Suggested-by: Laszlo Ersek Signed-off-by: Philippe Mathieu-Daude

Re: [edk2-devel] [PATCH v2 0/3] UefiCpuPkg/CpuFeature: Introduce First to indicate 1st unit.

2020-02-13 Thread Laszlo Ersek
Hi Ray, On 02/13/20 15:15, Ni, Ray wrote: > Laszlo, > I forgot to add you to CC list. > Do you have any comments on the patch set? Thanks for the ping -- no comments for now; please go ahead. I'm super swamped with todos and OVMF doesn't use RegisterCpuFeaturesLib or CpuCommonFeaturesLib, so I

Re: [edk2-devel] [PATCH v3 1/2] UefiCpuPkg: Remove FIT based microcode shadow logic from MpInitLib.

2020-02-13 Thread Michael D Kinney
Reviewed-by: Michael D Kinney Mike > -Original Message- > From: devel@edk2.groups.io On > Behalf Of Siyuan, Fu > Sent: Wednesday, February 12, 2020 5:57 PM > To: devel@edk2.groups.io > Cc: Dong, Eric ; Ni, Ray > ; Laszlo Ersek > Subject: [edk2-devel] [PATCH v3 1/2] UefiCpuPkg: Remove

Re: [edk2-devel] [RFC PATCH 1/1] OvmfPkg: add 'initrd' shell command to expose Linux initrd via device path

2020-02-13 Thread Ni, Ray
> -Original Message- > From: Laszlo Ersek > Sent: Friday, February 14, 2020 7:15 AM > To: Ni, Ray ; devel@edk2.groups.io; Ard Biesheuvel > > Cc: l...@nuviainc.com; phi...@redhat.com; Gao, Zhichao > > Subject: Re: [edk2-devel] [RFC PATCH 1/1] OvmfPkg: add 'initrd' shell > command to

Re: [edk2-devel] [PATCH v3] IntelSiliconPkg: FIT based shadow microcode PPI support.

2020-02-13 Thread Siyuan, Fu
Hi Mike See my reply for the ASSERT and magic number around FIT table parsing code. > -Original Message- > From: Kinney, Michael D > Sent: 2020年2月13日 8:58 > To: devel@edk2.groups.io; Fu, Siyuan ; Kinney, Michael > D > Cc: Ni, Ray ; Chaganty, Rangasai V > > Subject: RE: [edk2-devel]

Re: [edk2-devel] [PATCH 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Laszlo Ersek
Hi Christopher, (1) Please CC the CryptoPkg maintainers on CryptoPkg patches. On 02/13/20 00:41, Zurcher, Christopher J wrote: > This is required for interfaces such as EVP to retrieve algorithms > by name. (2) Apologies, I don't understand this explanation. There don't seem to be any users for

[edk2-devel] [PATCH v3 1/2] CryptoPkg/OpensslLib: Add "sort" keyword to header file parsing loop

2020-02-13 Thread Zurcher, Christopher J
This prevents the .inf files from being randomized after every run of process_files.pl. Cc: Jian J Wang Cc: Xiaoyu Lu Signed-off-by: Christopher J Zurcher --- CryptoPkg/Library/OpensslLib/OpensslLib.inf | 66 ++-- CryptoPkg/Library/OpensslLib/OpensslLibCrypto.inf | 62

[edk2-devel] [PATCH v3 0/2] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Zurcher, Christopher J
In order to implement the EVP interface, the EVP_get_digestbyname function requires the desired digest to be already initialized. Removing the "no-autoalginit" build option will allow algorithms to be retrieved by name. I plan to submit a future patch with an EVP implementation; the OpenSSL

[edk2-devel] [PATCH v3 2/2] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Zurcher, Christopher J
This is enabling a future EVP implementation to utilize the EVP_get_digestbyname() function. Cc: Jian J Wang Cc: Xiaoyu Lu Signed-off-by: Christopher J Zurcher --- CryptoPkg/Library/Include/openssl/opensslconf.h | 3 --- CryptoPkg/Library/OpensslLib/process_files.pl | 1 - 2 files changed,

Re: [edk2-devel] [PATCH v4 07/40] UefiCpuPkg: Implement library support for VMGEXIT

2020-02-13 Thread Dong, Eric
Hi Tom, For this patch, I found the function implementations not have function header comments for them. This is not follow edk2 coding style, please update them. Thanks, Eric -Original Message- From: devel@edk2.groups.io On Behalf Of Lendacky, Thomas Sent: Wednesday, February 5, 2020

Re: [edk2-devel] [PATCH 2/3] MdeModulePkg: Issues reported by ECC in EDK2.

2020-02-13 Thread Liming Gao
Reviewed-by: Liming Gao > -Original Message- > From: devel@edk2.groups.io On Behalf Of GuoMinJ > Sent: Thursday, February 13, 2020 4:34 PM > To: devel@edk2.groups.io > Cc: GuoMinJ > Subject: [edk2-devel] [PATCH 2/3] MdeModulePkg: Issues reported by ECC in > EDK2. > >

[edk2-devel] [edk2-platforms] Building a platform: which edk2 revision to choose?

2020-02-13 Thread Felix Polyudov
I'm trying to build one of the board packages from the edk2-platform repository. (I'm building WhiskeylakeOpenBoardPkg, but I suspect the problem exists for most of the board packages). The build process fails (I'm using build instructions from

Re: [edk2-devel] [RFC PATCH 1/1] OvmfPkg: add 'initrd' shell command to expose Linux initrd via device path

2020-02-13 Thread Laszlo Ersek
On 02/12/20 15:21, Ni, Ray wrote: >> (3) However: I think this should be added as a Dynamic Command instead. >> I'm basing this on the message of commit 0961002352e9 ("ShellPkg/tftp: >> Convert from NULL class library to Dynamic Command", 2017-11-28), which >> is the first commit in edk2 ever to

Re: [edk2-devel] [PATCH 1/1] CryptoPkg/OpensslLib: Remove "no-autoalginit" flag from OpenSSL build

2020-02-13 Thread Zurcher, Christopher J
> -Original Message- > From: devel@edk2.groups.io On Behalf Of Laszlo Ersek > Sent: Thursday, February 13, 2020 15:29 > To: devel@edk2.groups.io; Zurcher, Christopher J > > Subject: Re: [edk2-devel] [PATCH 1/1] CryptoPkg/OpensslLib: Remove "no- > autoalginit" flag from OpenSSL build > >

Re: [edk2-devel] [PATCH v3] IntelSiliconPkg: FIT based shadow microcode PPI support.

2020-02-13 Thread Siyuan, Fu
Hi, Mike Thanks for your comments, I will update patch accordingly and send a V4 for this. Best Regards Siyuan > -Original Message- > From: Kinney, Michael D > Sent: 2020年2月13日 8:58 > To: devel@edk2.groups.io; Fu, Siyuan ; Kinney, Michael > D > Cc: Ni, Ray ; Chaganty, Rangasai V >

Re: [edk2-devel] [PATCH v3 2/2] MdePkg: Remove FIT table industry standard header file.

2020-02-13 Thread Michael D Kinney
Reviewed-by: Michael D Kinney Mike > -Original Message- > From: devel@edk2.groups.io On > Behalf Of Siyuan, Fu > Sent: Wednesday, February 12, 2020 5:57 PM > To: devel@edk2.groups.io > Cc: Kinney, Michael D ; > Gao, Liming > Subject: [edk2-devel] [PATCH v3 2/2] MdePkg: Remove FIT >

Re: [edk2-devel] [edk2-platforms] Building a platform: which edk2 revision to choose?

2020-02-13 Thread Agyeman, Prince
Hi Felix, Can you include a log or details of the build error you're seeing ? Also what are the FSP , edk2-non-osi, edk2-platform and edk2 commit IDs you are using ? Thanks Prince Prince From: devel@edk2.groups.io On Behalf Of Felix Polyudov Sent: Thursday, February 13, 2020 3:11 PM To:

Re: [edk2-devel] [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsCertHashFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
Jiewen, > -Original Message- > From: Yao, Jiewen > Sent: Friday, February 14, 2020 8:54 AM > To: Wang, Jian J ; devel@edk2.groups.io > Cc: Zhang, Chao B ; Laszlo Ersek > > Subject: RE: [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate > error and search result in

Re: [edk2-devel] [PATCH 2/3] MdeModulePkg: Issues reported by ECC in EDK2.

2020-02-13 Thread Wu, Hao A
> -Original Message- > From: devel@edk2.groups.io [mailto:devel@edk2.groups.io] On Behalf Of > GuoMinJ > Sent: Thursday, February 13, 2020 4:34 PM > To: devel@edk2.groups.io > Cc: GuoMinJ > Subject: [edk2-devel] [PATCH 2/3] MdeModulePkg: Issues reported by ECC in > EDK2. > >

[edk2-devel] [PATCH v4] IntelSiliconPkg: FIT based shadow microcode PPI support.

2020-02-13 Thread Siyuan, Fu
V4 Changes: Adjust EDKII_MICROCODE_SHADOW_INFO_HOB structure definition for better alignment and understanding. Add EFI_MICROCODE_STORAGE_TYPE_FLASH_CONTEXT structure definition. Fix a typo in EFI_MICROCODE_STORAGE_TYPE_FLASH_GUID. Merge ShadowMicrocodePei.h header into c file. Correct file header

[edk2-devel] [PATCH 1/1] MdeModulePkg/Pci: Fixed SCT Issues in NonDiscoverablePciDevice.

2020-02-13 Thread Gaurav Jain
GetBarAttributes, MemRead, MemWrite consistency test failed with Invalid BarIndex. Added check for BarIndex and return Invalid Parameter. PCI Controller Attribute operation with Unsupported Attributes is failing. Added check to return Unsupported when wrong attributed are set. Signed-off-by:

Re: [edk2-devel] [patch 1/2] MdeModulePkg/String.c: Zero memory before free (CVE-2019-14558)

2020-02-13 Thread Dong, Eric
Reviewed-by: Eric Dong -Original Message- From: Bi, Dandan Sent: Thursday, February 13, 2020 12:03 PM To: devel@edk2.groups.io Cc: Gao, Liming ; Dong, Eric ; Wang, Jian J Subject: [patch 1/2] MdeModulePkg/String.c: Zero memory before free (CVE-2019-14558) REF:

Re: [edk2-devel] [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsCertHashFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Fine. Thanks for the update. > -Original Message- > From: Wang, Jian J > Sent: Friday, February 14, 2020 11:32 AM > To: Yao, Jiewen ; devel@edk2.groups.io > Cc: Zhang, Chao B ; Laszlo Ersek > > Subject: RE: [PATCH 6/9] SecurityPkg/DxeImageVerificationLib: Differentiate > error and

Re: [edk2-devel] [edk2-platforms] Building a platform: which edk2 revision to choose?

2020-02-13 Thread Liming Gao
Felix: I always pull the latest edk2 and edk2-platform, then build it. Thanks Liming From: devel@edk2.groups.io On Behalf Of Felix Polyudov Sent: Friday, February 14, 2020 7:11 AM To: devel@edk2.groups.io Cc: Kubacki, Michael A Subject: [edk2-devel] [edk2-platforms] Building a platform: which

[edk2-devel] OVMF and MEMFD_BASE_ADDRESS values.

2020-02-13 Thread Andrew Fish via Groups.Io
I'm trying to understand the constraints around the value used with MEMFD_BASE_ADDRESS? The reason I'm asking is I've been asked to remove firmware from using lower memory addresses in the low 0x80 range as it is taking up too many ASLR bits in low memory VMs or some such. At least on my

Re: [edk2-devel] [edk2-platforms] [PATCH v2 4/4] WhiskeylakeOpenBoardPkg/UpXtreme: Add DSC and build files

2020-02-13 Thread Chiu, Chasel
Reviewed-by: Chasel Chiu > -Original Message- > From: Agyeman, Prince > Sent: Friday, February 14, 2020 1:55 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > > Subject: [edk2-platforms] [PATCH v2 4/4] > WhiskeylakeOpenBoardPkg/UpXtreme: Add DSC and build

Re: [edk2-devel] [edk2-platforms] [PATCH v2 1/4] WhiskeylakeOpenBoardPkg/WhiskeylakeURvp: Remove BoardFuncInit

2020-02-13 Thread Chiu, Chasel
Reviewed-by: Chasel Chiu > -Original Message- > From: Agyeman, Prince > Sent: Friday, February 14, 2020 1:55 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > > Subject: [edk2-platforms] [PATCH v2 1/4] > WhiskeylakeOpenBoardPkg/WhiskeylakeURvp: Remove

Re: [edk2-devel] [edk2-platforms] [PATCH v2 2/4] WhiskeylakeOpenBoardPkg: Add UpXtreme board ID

2020-02-13 Thread Chiu, Chasel
Reviewed-by: Chasel Chiu > -Original Message- > From: Agyeman, Prince > Sent: Friday, February 14, 2020 1:55 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > > Subject: [edk2-platforms] [PATCH v2 2/4] WhiskeylakeOpenBoardPkg: Add > UpXtreme board ID > >

Re: [edk2-devel] [patch 2/2] MdeModulePkg/DisplayEngine: Zero memory before free (CVE-2019-14558)

2020-02-13 Thread Dong, Eric
Reviewed-by: Eric Dong -Original Message- From: Bi, Dandan Sent: Thursday, February 13, 2020 12:03 PM To: devel@edk2.groups.io Cc: Gao, Liming ; Dong, Eric ; Wang, Jian J Subject: [patch 2/2] MdeModulePkg/DisplayEngine: Zero memory before free (CVE-2019-14558) REF:

[edk2-devel] [PATCH v2 01/10] SecurityPkg/DxeImageVerificationLib: Fix memory leaks(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 Pointer HashCtx used in IsCertHashFoundInDatabase() is not freed inside the while-loop, if it will run more than once. Cc: Jiewen Yao Cc: Chao Zhang Signed-off-by: Jian J Wang Reviewed-by: Jiewen Yao ---

[edk2-devel] [PATCH v2 00/10] Fix false negative issue in DxeImageVerificationHandler

2020-02-13 Thread Wang, Jian J
> v2 changes: >- Change IsCertHashFoundInDatabase to IsCertHashFoundInDbx (patch 10) >- Update result handling to all calling to IsCertHashFoundInDatabase > to be consistent (patch 6) >- Fix commit message and title length issue caught by PatchCheck tool REF:

[edk2-devel] [PATCH v2 02/10] SecurityPkg/DxeImageVerificationLib: reject CertStack.CertNumber==0 per DBX(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
In case the signers' certificate stack, retrieved from the PE/COFF image's Authenticode blob, has zero elements (=there are zero signer certificates), then we should consider the image forbidden by DBX, not accepted by DBX. Cc: Jiewen Yao Cc: Chao Zhang Signed-off-by: Jian J Wang Reviewed-by:

[edk2-devel] [PATCH v2 04/10] SecurityPkg/DxeImageVerificationLib: avoid bypass in fetching dbx(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 In timestamp check after the cert is found in db, the original code jumps to 'Done' if any error happens in fetching dbx variable. At any of the jump, VerifyStatus equals to TRUE, which means allowed-by-db. This should not be allowed except

[edk2-devel] [PATCH v2 09/10] SecurityPkg/DxeImageVerificationLib: Differentiate error/search result (2)(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 To avoid false-negative issue in check hash against dbx, both error condition (as return value) and check result (as out parameter) of IsSignatureFoundInDatabase() are added. So the caller of this function will know exactly if a failure is

[edk2-devel] [PATCH v2 07/10] SecurityPkg/DxeImageVerificationLib: tighten default result(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 All intermediate results inside this function will be checked and returned immediately upon any failure or error, like out-of-resource, hash calculation error or certificate retrieval failure. Cc: Jiewen Yao Cc: Chao Zhang Signed-off-by:

[edk2-devel] [PATCH v2 08/10] SecurityPkg/DxeImageVerificationLib: plug Data leak in IsForbiddenByDbx()(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
From: Laszlo Ersek REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 If the second GetVariable() call for "dbx" fails, in IsForbiddenByDbx(), we have to free Data. Jump to "Done" for that. Cc: Jiewen Yao Cc: Chao Zhang Signed-off-by: Laszlo Ersek Reviewed-by: Jiewen Yao ---

[edk2-devel] [PATCH v2 06/10] SecurityPkg/DxeImageVerificationLib: Differentiate error/search result (1)(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 To avoid false-negative issue in check hash against dbx, both error condition (as return value) and check result (as out parameter) of IsCertHashFoundInDatabase() are added. So the caller of this function will know exactly if a failure is

[edk2-devel] [PATCH v2 05/10] SecurityPkg/DxeImageVerificationLib: refactor db/dbx fetching code(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 The dbx fetching code inside the while/for-loop causes code hard to understand. Since there's no need to get dbx more than once, this patch simplify the code logic by moving related code to be outside the while- loop. db fetching code is

[edk2-devel] [PATCH v2 10/10] SecurityPkg/DxeImageVerificationLib: change IsCertHashFoundInDatabase name(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
IsCertHashFoundInDatabase() is actually used only for searching dbx, according to the function logic, its comments and its use cases. Changing it to IsCertHashFoundInDbx to avoid confusion. REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 Cc: Jiewen Yao Cc: Chao Zhang Signed-off-by:

[edk2-devel] [PATCH v2 03/10] SecurityPkg/DxeImageVerificationLib: fix wrong fetch dbx in IsAllowedByDb(CVE-2019-14575)

2020-02-13 Thread Wang, Jian J
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1608 Normally two times of calling gRT->GetVariable() are needed to get the data of a variable: get the variable size by passing zero variable size, and then allocate enough memory and pass the correct variable size and buffer. But in the inner

Re: [edk2-devel] [edk2-platform][patch] FitGen: Add FIT spec revision in FitGen tool help message

2020-02-13 Thread Bob Feng
Reviewed-by: Bob Feng -Original Message- From: Gao, Liming Sent: Friday, February 14, 2020 3:51 PM To: devel@edk2.groups.io Cc: Feng, Bob C ; Lohr, Paul A Subject: [edk2-platform][patch] FitGen: Add FIT spec revision in FitGen tool help message BZ:

Re: [edk2-devel] [PATCH v2 06/10] SecurityPkg/DxeImageVerificationLib: Differentiate error/search result (1)(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Friday, February 14, 2020 3:28 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > ; Laszlo Ersek > Subject: [PATCH v2 06/10] SecurityPkg/DxeImageVerificationLib: Differentiate > error/search result

Re: [edk2-devel] [PATCH v2 10/10] SecurityPkg/DxeImageVerificationLib: change IsCertHashFoundInDatabase name(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Friday, February 14, 2020 3:28 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH v2 10/10] SecurityPkg/DxeImageVerificationLib: change > IsCertHashFoundInDatabase

[edk2-devel] [edk2-platform][patch] FitGen: Add FIT spec revision in FitGen tool help message

2020-02-13 Thread Liming Gao
BZ: https://bugzilla.tianocore.org/show_bug.cgi?id=2483 Signed-off-by: Liming Gao Cc: Bob Feng Cc: Paul Lohr --- Silicon/Intel/Tools/FitGen/FitGen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Silicon/Intel/Tools/FitGen/FitGen.c b/Silicon/Intel/Tools/FitGen/FitGen.c

[edk2-devel] [edk2-platforms] [PATCH v2 1/4] WhiskeylakeOpenBoardPkg/WhiskeylakeURvp: Remove BoardFuncInit

2020-02-13 Thread Agyeman, Prince
Removes BoardFuncInit related functionality in WhiskeylakeURvp. Co-authored-by: Michael Kubacki Cc: Chasel Chiu Cc: Nate DeSimone Signed-off-by: Prince Agyeman --- .../Library/BoardInitLib/BoardFunc.c | 19 .../Library/BoardInitLib/BoardFunc.h | 20

Re: [edk2-devel] [RFC PATCH 1/1] MdeModulePkg/PiDxeS3BootScriptLib: Use SafeIntLib to avoid truncation

2020-02-13 Thread Philippe Mathieu-Daudé
On 2/13/20 7:29 PM, Philippe Mathieu-Daude wrote: Math expressions written in terms of SafeIntLib function calls are easily readable, making review trivial. Convert the truncation checks added by commit 322ac05f8 to SafeIntLib calls. Cc: Jian J Wang Cc: Hao A Wu Cc: Eric Dong Suggested-by:

Re: [edk2-devel] [PATCH 9/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and search result in IsSignatureFoundInDatabase(CVE-2019-14575)

2020-02-13 Thread Zhang, Chao B
Ack-by : Chao Zhang -Original Message- From: devel@edk2.groups.io On Behalf Of Wang, Jian J Sent: Thursday, February 6, 2020 10:20 PM To: devel@edk2.groups.io Cc: Yao, Jiewen ; Zhang, Chao B Subject: [edk2-devel] [PATCH 9/9] SecurityPkg/DxeImageVerificationLib: Differentiate error and

Re: [edk2-devel] [edk2-platforms] [PATCH 4/4] WhiskeylakeOpenBoardPkg/UpXtreme: Add DSC and build files

2020-02-13 Thread Chiu, Chasel
Hi Prince, Please see my comments inline. Thanks, Chasel > -Original Message- > From: Agyeman, Prince > Sent: Thursday, February 13, 2020 9:38 AM > To: devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > > Subject: [edk2-platforms] [PATCH 4/4]

Re: [edk2-devel] [PATCH v2 0/3] UefiCpuPkg/CpuFeature: Introduce First to indicate 1st unit.

2020-02-13 Thread Dong, Eric
For the serial: Reviewed-by: Eric Dong -Original Message- From: devel@edk2.groups.io On Behalf Of Ray Ni Sent: Tuesday, November 26, 2019 2:16 PM To: devel@edk2.groups.io Subject: [edk2-devel] [PATCH v2 0/3] UefiCpuPkg/CpuFeature: Introduce First to indicate 1st unit. Ray Ni (3):

[edk2-devel] [PATCH 1/3] FmpDevicePkg/FmpDxe: Issues reported by ECC in EDK2.

2020-02-13 Thread GuoMinJ
https://bugzilla.tianocore.org/show_bug.cgi?id=2515 Change the FmpDevicePkg to match the ECC check rule Signed-off-by: GuoMinJ --- FmpDevicePkg/FmpDxe/Dependency.c | 4 ++-- FmpDevicePkg/FmpDxe/Dependency.h | 2 +- FmpDevicePkg/FmpDxe/FmpDxe.c | 2 +- 3 files changed, 4 insertions(+), 4

[edk2-devel] [PATCH 3/3] SecurityPkg: Issues reported by ECC in EDK2.

2020-02-13 Thread GuoMinJ
https://bugzilla.tianocore.org/show_bug.cgi?id=2515 Change the SecurityPkg to match the ECC check rule Signed-off-by: GuoMinJ --- SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.c | 4 ++-- SecurityPkg/Tcg/Tcg2Pei/Tcg2Pei.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git

[edk2-devel] [PATCH 2/3] MdeModulePkg: Issues reported by ECC in EDK2.

2020-02-13 Thread GuoMinJ
https://bugzilla.tianocore.org/show_bug.cgi?id=2515 Change the MdeModulePkg to match the ECC check rule Signed-off-by: GuoMinJ --- MdeModulePkg/Bus/Pci/PciBusDxe/PciEnumeratorSupport.c | 4 ++-- MdeModulePkg/Bus/Pci/SdMmcPciHcDxe/SdMmcPciHci.c | 2 +- MdeModulePkg/MdeModulePkg.uni

Re: [edk2-devel] [PATCH 1/3] FmpDevicePkg/FmpDxe: Issues reported by ECC in EDK2.

2020-02-13 Thread Liming Gao
Reviewed-by: Liming Gao > -Original Message- > From: devel@edk2.groups.io On Behalf Of GuoMinJ > Sent: Thursday, February 13, 2020 4:34 PM > To: devel@edk2.groups.io > Cc: GuoMinJ > Subject: [edk2-devel] [PATCH 1/3] FmpDevicePkg/FmpDxe: Issues reported by ECC > in EDK2. > >

Re: [edk2-devel] [PATCH 1/9] SecurityPkg/DxeImageVerificationLib: Fix memory leaks(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:19 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH 1/9] SecurityPkg/DxeImageVerificationLib: Fix memory > leaks(CVE-2019-14575) > > REF:

Re: [edk2-devel] [PATCH 3/9] SecurityPkg/DxeImageVerificationLib: fix wrong fetching dbx in IsAllowedByDb(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:19 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH 3/9] SecurityPkg/DxeImageVerificationLib: fix wrong fetching > dbx in

Re: [edk2-devel] [PATCH 2/9] SecurityPkg/DxeImageVerificationLib: reject CertStack.CertNumber==0 per DBX(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:19 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > ; Laszlo Ersek > Subject: [PATCH 2/9] SecurityPkg/DxeImageVerificationLib: reject > CertStack.CertNumber==0 per

Re: [edk2-devel] [PATCH 4/9] SecurityPkg/DxeImageVerificationLib: avoid bypass in fetching dbx in IsAllowedByDb(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:19 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH 4/9] SecurityPkg/DxeImageVerificationLib: avoid bypass in > fetching dbx in

[edk2-devel] RFC: Use Zoom for the next TianoCore Open Design Meeting

2020-02-13 Thread Ni, Ray
All, We started to use BlueJeans as the meeting service in September 2019 due to the unavailability of Zoom. But we met very bad meeting experience using BlueJeans. The connection is good for attendees from US, Taiwan, but bad for attendees from PRC mainland. It causes interaction between

Re: [edk2-devel] [PATCH 5/9] SecurityPkg/DxeImageVerificationLib: refactor db/dbx fetching code in IsAllowedByDb(CVE-2019-14575)

2020-02-13 Thread Yao, Jiewen
Good enhancement. Reviewed-by: Jiewen Yao > -Original Message- > From: Wang, Jian J > Sent: Thursday, February 6, 2020 10:19 PM > To: devel@edk2.groups.io > Cc: Yao, Jiewen ; Zhang, Chao B > > Subject: [PATCH 5/9] SecurityPkg/DxeImageVerificationLib: refactor db/dbx > fetching code in