diff options
author | Zhichao Gao <zhichao.gao@intel.com> | 2020-06-15 16:06:17 +0800 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2020-06-29 05:25:55 +0000 |
commit | acfd55579542de64418cd4fb1c5560524a79d61f (patch) | |
tree | ba0c1832f1a098d624a6d425ab96427225e1f997 /CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c | |
parent | 0060e0a694f3f249c3ec081b0e61287c36f64ebb (diff) | |
download | edk2-acfd55579542de64418cd4fb1c5560524a79d61f.tar.gz edk2-acfd55579542de64418cd4fb1c5560524a79d61f.tar.bz2 edk2-acfd55579542de64418cd4fb1c5560524a79d61f.zip |
CryptoPkg/BaseCryptLib: Add MARCO to disable the deprecated MD5
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=1682
MD5 is deprecated but it is required for compatible issue.
So add a MARCO for the platform to disable the usage of MD5 for
security.
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Xiaoyu Lu <xiaoyux.lu@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Siyuan Fu <siyuan.fu@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Signed-off-by: Zhichao Gao <zhichao.gao@intel.com>
Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
Diffstat (limited to 'CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c')
-rw-r--r-- | CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c b/CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c index a614b61ed4..8897fd25e6 100644 --- a/CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c +++ b/CryptoPkg/Library/BaseCryptLibOnProtocolPpi/CryptLib.c @@ -99,6 +99,7 @@ CryptoServiceNotAvailable ( // One-Way Cryptographic Hash Primitives
//=====================================================================================
+#ifndef DISABLE_MD5_DEPRECATED_INTERFACES
/**
Retrieves the size, in bytes, of the context buffer required for MD5 hash operations.
@@ -256,6 +257,7 @@ Md5HashAll ( {
CALL_CRYPTO_SERVICE (Md5HashAll, (Data, DataSize, HashValue), FALSE);
}
+#endif
/**
Retrieves the size, in bytes, of the context buffer required for SHA-1 hash operations.
|