[edk2-devel] [PATCH v6 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-15 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney

[edk2-devel] [PATCH v6 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-15 Thread Sukerkar, Amol N
This patch implements the fixes and enhancement to BaseHashApiLib in the following manner: - Remove reference to MD4 and MD5 hashing algorithms as they are deprecated; - Align the enumeration for hashing algorithmswith the one used in TPM 2.0 implementation defined in IndustryStandard/Tpm20.h;

[edk2-devel] [PATCH v6 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-15 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit aligns the baseHashApiLib with TPM 2.0 Implementation as follows: - Remove reference to MD4 and MD5 algorithms as they are deprecated - Align the enumerations for hashing algoerithms with the one used in TPM 2.0 implementation

Re: [edk2-devel] [PATCH v4 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-15 Thread Sukerkar, Amol N
, Michael D Sent: Saturday, February 15, 2020 12:44 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Gao, Liming Subject: RE: [PATCH v4 0/2] Enhancement and Fixes to BaseHashApiLib Amol, FixedPcdGet32() does not apply to this use

Re: [edk2-devel] [PATCH v4 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-15 Thread Sukerkar, Amol N
-Original Message- From: Kinney, Michael D Sent: Saturday, February 15, 2020 12:28 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Gao, Liming Subject: RE: [PATCH v4 0/2] Enhancement and Fixes to BaseHashApiLib Hi Amol

[edk2-devel] [PATCH v5 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-15 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit aligns the baseHashApiLib with TPM 2.0 Implementation as follows: - Remove reference to MD4 and MD5 algorithms as they are deprecated - Align the enumerations for hashing algoerithms with the one used in TPM 2.0 implementation

[edk2-devel] [PATCH v5 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-15 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney

[edk2-devel] [PATCH v5 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-15 Thread Sukerkar, Amol N
This patch implements the fixes and enhancement to BaseHashApiLib in the following manner: - Remove reference to MD4 and MD5 hashing algorithms as they are deprecated; - Align the enumeration for hashing algorithmswith the one used in TPM 2.0 implementation defined in IndustryStandard/Tpm20.h;

[edk2-devel] [PATCH v4 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-14 Thread Sukerkar, Amol N
This patch implements the fixes and enhancement to BaseHashApiLib in the following manner: - Remove reference to MD4 and MD5 hashing algorithms as they are deprecated; - Align the enumeration for hashing algorithmswith the one used in TPM 2.0 implementation defined in IndustryStandard/Tpm20.h;

[edk2-devel] [PATCH v4 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney

[edk2-devel] [PATCH v4 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit aligns the baseHashApiLib with TPM 2.0 Implementation as follows: - Remove reference to MD4 and MD5 algorithms as they are deprecated - Align the enumerations for hashing algoerithms with the one used in TPM 2.0 implementation

Re: [edk2-devel] [PATCH v3 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-14 Thread Sukerkar, Amol N
understanding is accurate? Thanks, Amol -Original Message- From: Kinney, Michael D Sent: Friday, February 14, 2020 5:04 PM To: devel@edk2.groups.io; Sukerkar, Amol N ; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Gao, Liming Subject: RE: [edk2-devel] [PATCH

Re: [edk2-devel] [PATCH v2 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-14 Thread Sukerkar, Amol N
Hi Mike, Addressed all the comments and sent newer version of patch. Thanks, Amol -Original Message- From: Kinney, Michael D Sent: Friday, February 14, 2020 3:38 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Gao

[edk2-devel] [PATCH v3 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit aligns the baseHashApiLib with TPM 2.0 Implementation as follows: - Remove reference to MD4 and MD5 algorithms as they are deprecated - Align the enumerations for hashing algoerithms with the one used in TPM 2.0 implementation

[edk2-devel] [PATCH v3 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney

[edk2-devel] [PATCH v3 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-14 Thread Sukerkar, Amol N
This patch implements the fixes and enhancement to BaseHashApiLib in the following manner: - Remove reference to MD4 and MD5 hashing algorithms as they are deprecated; - Align the enumeration for hashing algorithmswith the one used in TPM 2.0 implementation defined in IndustryStandard/Tpm20.h;

[edk2-devel] [PATCH v2 0/2] Enhancement and Fixes to BaseHashApiLib

2020-02-14 Thread Sukerkar, Amol N
This patch implements the fixes and enhancement to BaseHashApiLib in the following manner: - Remove reference to MD4 and MD5 hashing algorithms as they are deprecated; - Align the enumeration for hashing algorithmswith the one used in TPM 2.0 implementation defined in IndustryStandard/Tpm20.h;

[edk2-devel] [PATCH v2 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney

[edk2-devel] [PATCH v1 2/2] CryptoPkg/BaseHashApiLib: Change PcdHashApiLibPolicy type to FixedAtBuild

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit changes the PCD PcdHashApiLibPolicy to the type PcdsFixedAtBuild so as to be able to optimize away the unused hashing algorithms in HashApiLib instance used by a driver. Cc: Jiewen Yao Cc: Michael D Kinney Signed-off-by: Amol

[edk2-devel] [PATCH v1 1/2] CryptoPkg/BaseHashApiLib: Align BaseHashApiLib with TPM 2.0 Implementation

2020-02-14 Thread Sukerkar, Amol N
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2511 This commit aligns the baseHashApiLib with TPM 2.0 Implementation as follows: - Remove reference to MD4 and MD5 algorithms as they are deprecated - Align the enumerations for hashing algoerithms with the one used in TPM 2.0 implementation

Re: [edk2-devel] [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-04 Thread Sukerkar, Amol N
Thanks, Jiewen! I will start the process. ~ Amol -Original Message- From: Yao, Jiewen Sent: Tuesday, February 04, 2020 4:20 PM To: Sukerkar, Amol N ; Kinney, Michael D ; devel@edk2.groups.io Cc: Wang, Jian J Subject: RE: [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified

Re: [edk2-devel] [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-04 Thread Sukerkar, Amol N
Message- From: Yao, Jiewen Sent: Tuesday, February 04, 2020 4:06 PM To: Sukerkar, Amol N ; Kinney, Michael D ; devel@edk2.groups.io Cc: Wang, Jian J Subject: RE: [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API Amol We are in the process to deprecating SHA1

Re: [edk2-devel] [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-04 Thread Sukerkar, Amol N
Hi Mike, Jiewen and Jian, Do I need to follow any crypto review guidelines for this patch? I am not enabling any new crypto. Need your input. Thanks, Amol -Original Message- From: Sukerkar, Amol N Sent: Tuesday, February 04, 2020 10:10 AM To: Kinney, Michael D ; Yao, Jiewen ; devel

Re: [edk2-devel] [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-04 Thread Sukerkar, Amol N
: Tuesday, February 04, 2020 9:26 AM To: Yao, Jiewen ; devel@edk2.groups.io; Kinney, Michael D ; Sukerkar, Amol N Cc: Wang, Jian J Subject: RE: [Patch v10 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API Jiewen, I think UINT8 is fine. We can change default to 0x04 in DEC file

Re: [edk2-devel] [PATCH v9 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-03 Thread Sukerkar, Amol N
Thanks, Mike! Sorry, I seemed to have missed that. I reviewed and accept the change. ~ Amol -Original Message- From: Kinney, Michael D Sent: Monday, February 03, 2020 3:19 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal

Re: [edk2-devel] [PATCH v9 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-03 Thread Sukerkar, Amol N
Hi Mike, I have no issue with generating new GUIDs. Thanks, Amol -Original Message- From: Kinney, Michael D Sent: Monday, February 03, 2020 2:50 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Musti, Srinivas

Re: [edk2-devel] [PATCH v9 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-03 Thread Sukerkar, Amol N
Thanks for the review, Mike! ~ Amol -Original Message- From: devel@edk2.groups.io On Behalf Of Michael D Kinney Sent: Monday, February 03, 2020 11:36 AM To: devel@edk2.groups.io; Sukerkar, Amol N ; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Musti, Srinivas

[edk2-devel] [PATCH v9 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-02-03 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Amol N Sukerkar --- Notes: v6 - removed file CryptoPkgTokenSpace.h v7 - fixed typo v8 - Fixed Author and signed-off-by name

[edk2-devel] [PATCH v9 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-03 Thread Sukerkar, Amol N
Currently, the UEFI drivers using the SHA/SM3 hashing algorithms use hard-coded API to calculate the hash, for instance, sha_256(...), etc. Since SHA384 and/or SM3_256 are being increasingly adopted for robustness, it becomes cumbersome to modify each driver that calls into hash calculating API.

[edk2-devel] [PATCH v9 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-02-03 Thread Sukerkar, Amol N
This commit introduces a Unified Hash API to calculate hash using a hashing algorithm specified by the PCD, PcdHashApiLibPolicy. This library interfaces with the various hashing API, such as, MD4, MD5, SHA1, SHA256, SHA512 and SM3_256 implemented in BaseCryptLib. The user can calculate the desired

[edk2-devel] [PATCH v8 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash

2020-01-31 Thread Sukerkar, Amol N
Currently, the UEFI drivers using the SHA/SM3 hashing algorithms use hard-coded API to calculate the hash, for instance, sha_256(...), etc. Since SHA384 and/or SM3_256 are being increasingly adopted for robustness, it becomes cumbersome to modify each driver that calls into hash calculating API.

[edk2-devel] [PATCH v8 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-01-31 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Amol N Sukerkar --- Notes: v6 - removed file CryptoPkgTokenSpace.h v7 - fixed typo v8 - Fixed Author and signed-off-by name

[edk2-devel] [PATCH v8 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-01-31 Thread Sukerkar, Amol N
This commit introduces a Unified Hash API to calculate hash using a hashing algorithm specified by the PCD, PcdHashApiLibPolicy. This library interfaces with the various hashing API, such as, MD4, MD5, SHA1, SHA256, SHA512 and SM3_256 implemented in BaseCryptLib. The user can calculate the desired

[edk2-devel] [PATCH v7 2/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-01-29 Thread Sukerkar, Amol N
hash by setting PcdHashApiLibPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v7 - Changed lib name to BaseHashApiLib - Changed HASH_API_CONTEXT to VOID* type CryptoPkg/Library/HashApiLib/BaseHashApiLib.c

[edk2-devel] [PATCH v7 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-01-29 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v6 - removed file CryptoPkgTokenSpace.h v7 - fixed typo CryptoPkg/CryptoPkg.dec | 6 +- 1 file changed, 5

[edk2-devel] [PATCH v7 0/2] CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API

2020-01-29 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (2): CryptoPkg: Add CryptoPkg Token Space GUID CryptoPkg/BaseHashApiLib: Implement Unified Hash Calculation API CryptoPkg/Library/HashApiLib/BaseHashApiLib.c | 333 CryptoPkg/CryptoPkg.dec | 26

Re: [edk2-devel] [PATCH v6 0/2] CryptoPkg/HashApiLib: Implement Unified Hash Calculation API

2020-01-29 Thread Sukerkar, Amol N
Ah, OK! It is clear to me now. Thanks, Mike! ~ Amol -Original Message- From: Kinney, Michael D Sent: Wednesday, January 29, 2020 4:16 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Musti, Srinivas ; Lakkimsetti

Re: [edk2-devel] [PATCH v6 0/2] CryptoPkg/HashApiLib: Implement Unified Hash Calculation API

2020-01-29 Thread Sukerkar, Amol N
rn. Thanks, Amol -----Original Message- From: Kinney, Michael D Sent: Wednesday, January 29, 2020 1:10 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Musti, Srinivas ; Lakkimsetti, Subash Subject: RE: [PATCH v6 0/2] CryptoPkg

[edk2-devel] [PATCH v6 2/2] CryptoPkg/HashApiLib: Implement Unified Hash Calculation API

2020-01-28 Thread Sukerkar, Amol N
hash by setting PcdHashApiLibPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v6 - Changed the PCD name to PcdHashApiLibPolicy - Changed the lib nabme to HashApiLib - Changes lib MODULE_TYPE to BASE

[edk2-devel] [PATCH v6 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-01-28 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v6 - removed file CryptoPkgTokenSpace.h CryptoPkg/CryptoPkg.dec | 6 +- 1 file changed, 5 insertions(+), 1 deletion

[edk2-devel] [PATCH v6 0/2] CryptoPkg/HashApiLib: Implement Unified Hash Calculation API

2020-01-28 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (2): CryptoPkg: Add CryptoPkg Token Space GUID CryptoPkg/HashApiLib: Implement Unified Hash Calculation API CryptoPkg/Library/HashApiLib/HashApiLib.c | 333 CryptoPkg/CryptoPkg.dec | 27 +- CryptoPkg

Re: [edk2-devel] [PATCH v5 0/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-28 Thread Sukerkar, Amol N
Thanks, Mike! I agree with the feedback below. I will upload the changes soon. ~ Amol -Original Message- From: Kinney, Michael D Sent: Sunday, January 26, 2020 12:48 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Kinney, Michael D Cc: Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin

[edk2-devel] [PATCH v5 2/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-23 Thread Sukerkar, Amol N
hash by setting PcdSystemHashPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- CryptoPkg/Library/BaseHashLib/BaseHashLib.c | 228 CryptoPkg/CryptoPkg.dec | 21 ++ CryptoPkg

[edk2-devel] [PATCH v5 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-01-23 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- CryptoPkg/CryptoPkg.dec | 7 ++- CryptoPkg/Include/Guid/CryptoPkgTokenSpace.h | 19 +++ 2 files

[edk2-devel] [PATCH v5 0/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-23 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (2): CryptoPkg: Add CryptoPkg Token Space GUID CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API CryptoPkg/Library/BaseHashLib/BaseHashLib.c | 228 CryptoPkg/CryptoPkg.dec | 28

Re: [edk2-devel] [PATCH v4 2/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-23 Thread Sukerkar, Amol N
; Sukerkar, Amol N Cc: Kinney, Michael D ; Yao, Jiewen ; Agrawal, Sachin ; Musti, Srinivas ; Lakkimsetti, Subash Subject: RE: [edk2-devel] [PATCH v4 2/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API Amol, One general comment in advance. The switch/case are using parameter HashPolicy

Re: [edk2-devel] [PATCH v4 2/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-23 Thread Sukerkar, Amol N
Thanks, Hot! I will change the license to reflect it. ~ Amol -Original Message- From: Tian, Hot Sent: Friday, January 17, 2020 4:33 PM To: devel@edk2.groups.io; Sukerkar, Amol N Cc: Kinney, Michael D ; Yao, Jiewen ; Wang, Jian J ; Agrawal, Sachin ; Musti, Srinivas ; Lakkimsetti

[edk2-devel] [PATCH v4 0/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-17 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (2): CryptoPkg: Add CryptoPkg Token Space GUID CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API CryptoPkg/Library/BaseHashLib/BaseHashLibCommon.c | 254 CryptoPkg/Library/BaseHashLib/BaseHashLibDxe.c| 100

[edk2-devel] [PATCH v4 2/2] CryptoPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-17 Thread Sukerkar, Amol N
hash by setting PcdSystemHashPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- CryptoPkg/Library/BaseHashLib/BaseHashLibCommon.c | 254 CryptoPkg/Library/BaseHashLib/BaseHashLibDxe.c| 100

[edk2-devel] [PATCH v4 1/2] CryptoPkg: Add CryptoPkg Token Space GUID

2020-01-17 Thread Sukerkar, Amol N
Added CryptoPkg Token Space GUID to be able to define PCDs. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- CryptoPkg/CryptoPkg.dec | 7 ++- CryptoPkg/Include/Guid/CryptoPkgTokenSpace.h | 19 +++ 2 files

Re: [edk2-devel] [PATCH v3 0/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-16 Thread Sukerkar, Amol N
Hi Mike, I had an offline conversation with Jian and, now, I agree on the point that bitmap will not optimize the API. I will work on changing back to switch..case. Thanks, Amol -Original Message- From: Sukerkar, Amol N Sent: Wednesday, January 15, 2020 9:26 PM To: Wang, Jian J

Re: [edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-16 Thread Sukerkar, Amol N
Thanks, Liming! ~ Amol -Original Message- From: Gao, Liming Sent: Thursday, January 16, 2020 5:31 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Wang, Jian J Cc: Kinney, Michael D ; Yao, Jiewen ; Agrawal, Sachin ; Musti, Srinivas Subject: RE: [edk2-devel] [PATCH v2 1/1

Re: [edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-16 Thread Sukerkar, Amol N
Sure, Liming! Please add edk2 2020 Q1 stable tag to this feature. I will follow the schedule. Thanks, Amol -Original Message- From: Gao, Liming Sent: Wednesday, January 15, 2020 9:36 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Wang, Jian J Cc: Kinney, Michael D ; Yao, Jiewen

Re: [edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
Thanks, Liming! How do I find out if it catches EDK 2020 Q1 stable tag? ~ Amol -Original Message- From: devel@edk2.groups.io On Behalf Of Liming Gao Sent: Wednesday, January 15, 2020 8:39 PM To: Sukerkar, Amol N ; devel@edk2.groups.io; Wang, Jian J Cc: Kinney, Michael D ; Yao, Jiewen

Re: [edk2-devel] [PATCH v3 0/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
, January 15, 2020 7:15 PM To: Kinney, Michael D ; Sukerkar, Amol N ; devel@edk2.groups.io Cc: Yao, Jiewen ; Agrawal, Sachin ; Musti, Srinivas ; Lakkimsetti, Subash Subject: RE: [PATCH v3 0/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API Mike, If I remember correctly

Re: [edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
Hi Liming, We already have a ticket filed in Bugzilla, https://bugzilla.tianocore.org/show_bug.cgi?id=2151. Would this be sufficient? Thanks, Amol -Original Message- From: Gao, Liming Sent: Tuesday, January 14, 2020 8:47 PM To: devel@edk2.groups.io; Wang, Jian J ; Sukerkar, Amol N

[edk2-devel] [PATCH v3 0/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (1): SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API SecurityPkg/Library/BaseHashLib/BaseHashLibCommon.c | 151 SecurityPkg/Library/BaseHashLib/BaseHashLibDxe.c| 100 + SecurityPkg/Library

[edk2-devel] [PATCH v3 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
hash by setting PcdSystemHashPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v2: - Fixed the commit message format V3: - Changed design to use global array instead of switch..case - Removed

Re: [edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-15 Thread Sukerkar, Amol N
Thanks, Jian! Please find my answer below. ~ Amol -Original Message- From: Wang, Jian J Sent: Tuesday, January 14, 2020 8:14 PM To: Sukerkar, Amol N ; devel@edk2.groups.io Cc: Kinney, Michael D ; Yao, Jiewen ; Agrawal, Sachin ; Musti, Srinivas Subject: RE: [PATCH v2 1/1

[edk2-devel] [PATCH v2 1/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-14 Thread Sukerkar, Amol N
hash by setting PcdSystemHashPolicy to appropriate value. Cc: Jiewen Yao Cc: Jian J Wang Cc: Michael D Kinney Signed-off-by: Sukerkar, Amol N --- Notes: v2: - Fixed the commit message format SecurityPkg/Library/BaseHashLib/BaseHashLibCommon.c | 252 SecurityPkg

[edk2-devel] [PATCH v2 0/1] SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API

2020-01-14 Thread Sukerkar, Amol N
://bugzilla.tianocore.org/show_bug.cgi?id=2151. Sukerkar, Amol N (1): SecurityPkg/BaseHashLib: Implement Unified Hash Calculation API SecurityPkg/Library/BaseHashLib/BaseHashLibCommon.c | 252 SecurityPkg/Library/BaseHashLib/BaseHashLibDxe.c| 122 ++ SecurityPkg/Library/BaseHashLib

[edk2-devel] [PATCH v1 1/1] SecurityPkg: BaseHashLib: Implement Unified Hash API-for-

2020-01-13 Thread Sukerkar, Amol N
From: "Sukerkar, Amol N" This commit introduces a Unified Hash API to calculate hash using a hashing algorithm specified by the PCD, PcdSystemHashPolicy. This library interfaces with the various hashing API, such as, MD4, MD5, SHA1, SHA256, SHA512 and SM3_256 implemented in CryptoPkg

[edk2-devel] [PATCH v1 0/1] *** Unified Hash Calucation API ***

2020-01-13 Thread Sukerkar, Amol N
From: "Sukerkar, Amol N" Currently the UEFI drivers using the SHA/SM3 hashing algorithms use hard-coded API to calculate the hash, such as, sha_256(…), etc. Since SHA384 and/or SM3 are being increasingly adopted, it becomes cumbersome to modify the driver with SHA384 or SM3 call

[edk2-devel] [PATCH v1 5/6] SecurityPkg/BaseHashLib: Modified the Registation Mechanism for BaseHashLib

2019-12-18 Thread Sukerkar, Amol N
of hashing algorithms based on PcdSystemHashPolicy. Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/BaseHashLib/BaseHashLib.c | 236 - SecurityPkg/Library/BaseHashLib/BaseHashLibDxe.c | 210 +++- SecurityPkg/Library/BaseHashLib

[edk2-devel] [PATCH v1 2/6] SecurityPkg/HashApiInstanceSha1: Implement API registration mechanism for SHA1

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA1 which registers the SHA1 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA1 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha1

[edk2-devel] [PATCH v1 0/6] SecurityPkg/BaseHashLib: Implement a Unified API for Hash Calculation

2019-12-18 Thread Sukerkar, Amol N
feedback from the community before we begin the process of making the changes to EDK2 repo. Alternatively, the design document is also attached to Bugzilla, https://bugzilla.tianocore.org/show_bug.cgi?id=2151. You can also provide the feedback in the Bugzilla. Sukerkar, Amol N (6): SecurityPkg

[edk2-devel] [PATCH v1 5/6] SecurityPkg/BaseHashLib: Modified the Registation Mechanism for BaseHashLib

2019-12-18 Thread Sukerkar, Amol N
of hashing algorithms based on PcdSystemHashPolicy. Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/BaseHashLib/BaseHashLib.c | 236 - SecurityPkg/Library/BaseHashLib/BaseHashLibDxe.c | 210 +++- SecurityPkg/Library/BaseHashLib

[edk2-devel] [PATCH v1 4/6] SecurityPkg/HashApiInstanceSha384: Implement API registration mechanism for SHA384

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA384 which registers the SHA384 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA384 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha384

[edk2-devel] [PATCH v1 3/6] SecurityPkg/HashApiInstanceSha256: Implement API registration mechanism for SHA256

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA256 which registers the SHA256 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA256 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha256

[edk2-devel] [PATCH v1 6/6] SecurityPkg/HashApiInstanceSM3: Implement API registration mechanism for SM3

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SM3 which registers the SM3 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SM3 hash algorithm. Signed-off-by: Subash Lakkimsetti Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSm3

[edk2-devel] [PATCH v1 3/6] SecurityPkg/HashApiInstanceSha256: Implement API registration mechanism for SHA256

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA256 which registers the SHA256 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA256 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha256

[edk2-devel] [PATCH v1 2/6] SecurityPkg/HashApiInstanceSha1: Implement API registration mechanism for SHA1

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA1 which registers the SHA1 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA1 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha1

[edk2-devel] [PATCH v1 0/6] SecurityPkg/BaseHashLib: Implement a Unified API for Hash Calculation

2019-12-18 Thread Sukerkar, Amol N
feedback from the community before we begin the process of making the changes to EDK2 repo. Alternatively, the design document is also attached to Bugzilla, https://bugzilla.tianocore.org/show_bug.cgi?id=2151. You can also provide the feedback in the Bugzilla. Sukerkar, Amol N (6): SecurityPkg

[edk2-devel] [PATCH v1 1/6] SecurityPkg/BaseHashLib: Implement a unified API for Hash Calculation

2019-12-18 Thread Sukerkar, Amol N
This implementation eliminates the need to use hard-coded API to calculate hash by PEI and DXE drivers by introducing a common and unified API for hash calculation. The common API will execute the hash algorithm specified by the PCD, PcdSystemHashPolicy. Signed-off-by: Sukerkar, Amol N

[edk2-devel] [PATCH v1 1/6] SecurityPkg/BaseHashLib: Implement a unified API for Hash Calculation

2019-12-18 Thread Sukerkar, Amol N
This implementation eliminates the need to use hard-coded API to calculate hash by PEI and DXE drivers by introducing a common and unified API for hash calculation. The common API will execute the hash algorithm specified by the PCD, PcdSystemHashPolicy. Signed-off-by: Sukerkar, Amol N

[edk2-devel] [PATCH v1 4/6] SecurityPkg/HashApiInstanceSha384: Implement API registration mechanism for SHA384

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SHA384 which registers the SHA384 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SHA384 hash algorithm (provided by PcdTpm2HashMask). Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSha384

[edk2-devel] [PATCH v1 6/6] SecurityPkg/HashApiInstanceSM3: Implement API registration mechanism for SM3

2019-12-18 Thread Sukerkar, Amol N
This is the HashApiInstance implementation for SM3 which registers the SM3 hash library in CryptoPkg with BaseHashLib based on whether a platform supports SM3 hash algorithm. Signed-off-by: Subash Lakkimsetti Signed-off-by: Sukerkar, Amol N --- SecurityPkg/Library/HashApiInstanceSm3