22ac5cc9d9
CryptoPkg: BaseCryptLib: Add RSA PSS verify support
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3314
This patch uses Openssl's EVP API's to perform RSASSA-PSS verification
of a binary blob.
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Guomin Jiang <guomin.jiang@intel.com >
Signed-off-by: Sachin Agrawal <sachin.agrawal@intel.com >
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com >
2021-05-14 03:35:33 +00:00
c812d3209c
CryptoPkg/BaseCryptLib: Retire HMAC SHA1 algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
HMAC SHA1 is not secure any longer.
Remove the HMAC SHA1 support from edk2.
Change the HMAC SHA1 field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
b6174e2d09
CryptoPkg/BaseCryptLib: Retire HMAC MD5 algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
HMAC MD5 is not secure any longer.
Remove the HMAC MD5 support from edk2.
Change the HMAC MD5 field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
80e28dcec8
CryptoPkg/BaseCryptLib: Retire Aes Ecb mode algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
Aes Ecb mode is not secure any longer.
Remove the Aes Ecb mode support from edk2.
Change the Aes Ecb mode field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
b8af2c9eda
CryptoPkg/BaseCryptLib: Retire the TDES algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
TDES is not secure any longer.
Remove the Tdes support from edk2.
Change the Tdes field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
c22a32e1ab
CryptoPkg/BaseCryptLib: Retire ARC4 algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
ARC4 is not secure any longer.
Remove the ARC4 support from edk2.
Change the ARC4 field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
0a6fc3d067
CryptoPkg/BaseCrpytLib: Retire MD4 algorithm
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1898
MD4 is not secure any longer.
Remove the MD4 support from edk2.
Change the MD4 field name in EDKII_CRYPTO_PROTOCOL to indicate the
function is unsupported any longer.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Siyuan Fu <siyuan.fu@intel.com >
Cc: Michael D Kinney <michael.d.kinney@intel.com >
Cc: Jiewen Yao <jiewen.yao@intel.com >
Cc: Philippe Mathieu-Daude <philmd@redhat.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com >
2020-05-15 07:22:36 +00:00
9025a014f9
CryptoPkg: Add RISC-V architecture for EDK2 CI.
...
Add RISC-V architecture for EDK2 CI testing.
BZ:2562:
https://bugzilla.tianocore.org/show_bug.cgi?id=2562
Signed-off-by: Abner Chang <abner.chang@hpe.com >
Co-authored-by: Daniel Schaefer <daniel.schaefer@hpe.com >
Reviewed-by: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Leif Lindholm <leif@nuviainc.com >
Cc: Gilbert Chen <gilbert.chen@hpe.com >
2020-04-03 17:09:12 +00:00
668621362f
CryptoPkg/BaseCryptLib: Add X509ConstructCertificateStackV().
...
https://bugzilla.tianocore.org/show_bug.cgi?id=2420
Add X509ConstructCertificateStackV() to BaseCryptLib that is
identical in behavior to X509ConstructCertificateStack(), but
it takes a VA_LIST parameter for the variable argument list.
The VA_LIST form of this function is required for BaseCryptLib
functions to be wrapped in a Protocol/PPI.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
2020-02-07 16:32:13 +00:00
422da35375
CryptoPkg/BaseCryptLibNull: Add missing HkdfSha256ExtractAndExpand()
...
https://bugzilla.tianocore.org/show_bug.cgi?id=2493
The BaseCryptLib was expanded to add the HkdfSha256ExtractAndExpand()
service in the following commit:
4b1b7c1913
When BaseCryptLibNull was added in the commit below, this new
service was not included.
d95de082da
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
2020-02-04 21:35:48 +00:00
9a1f14ad72
CryptoPkg/BaseCryptLib: remove HmacXxxGetContextSize interface
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1792
Hmac(Md5|Sha1|Sha256)GetContextSize() use a deprecated macro
HMAC_MAX_MD_CBLOCK defined in openssl. They should be dropped to
avoid misuses in the future. For context allocation and release,
use HmacXxxNew() and HmacXxxFree() instead.
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Laszlo Ersek <lersek@redhat.com >
Signed-off-by: Jian J Wang <jian.j.wang@intel.com >
Reviewed-by: Laszlo Ersek <lersek@redhat.com >
Reviewed-by: Xiaoyu Lu <xiaoyux.lu@intel.com >
2020-01-20 16:41:23 +00:00
a23fdff6fb
CryptoPkg/BaseCryptLib: replace HmacXxxInit API with HmacXxxSetKey
...
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1792
HmacXxxInit() is supposed to be initialize user supplied buffer as HMAC
context, as well as user supplied key. Currently it has no real use cases.
Due to BZ1792, the user has no way to get correct size of context buffer
after it's fixed, and then cannot make use of HmacXxxInit to initialize
it.
So it's decided to replace it with HmacXxxSetKey to keep the functionality
of supplying a key to HMAC, but drop all other initialization works. The
user can still get HMAC context via HmacXxxNew interface, which hides the
details about the context.
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Cc: Laszlo Ersek <lersek@redhat.com >
Signed-off-by: Jian J Wang <jian.j.wang@intel.com >
Reviewed-by: Laszlo Ersek <lersek@redhat.com >
Reviewed-by: Xiaoyu Lu <xiaoyux.lu@intel.com >
2020-01-20 16:41:23 +00:00
d95de082da
CryptoPkg: Add Null instance of the BaseCryptLib class
...
https://bugzilla.tianocore.org/show_bug.cgi?id=2257
Add a Null instance of the BaseCryptLib class. This lib instance
can be used as a template for new implementations of the BaseCryptLib
class and can also be used to reduce CI build times for build
checks that depend on the BaseCryptLib class.
Cc: Jian J Wang <jian.j.wang@intel.com >
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com >
Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com >
Reviewed-by: Jian J Wang <jian.j.wang@intel.com >
2019-10-23 18:37:19 -07:00