audk/CryptoPkg/Library/BaseCryptLib
Yi Li 0e7aa6bf9e CryptoPkg: Fix pem heap-buffer-overflow due to BIO_snprintf()
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=4075

Fake BIO_snprintf() does not actually print anything to buf,
it should return -1 as error.
0 will be considered a correct return value, the consumer may think that
the buf is valid and parse the buffer.
please refer to bugzilla link for details.

Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Xiaoyu Lu <xiaoyu1.lu@intel.com>
Cc: Guomin Jiang <guomin.jiang@intel.com>

Signed-off-by: Yi Li <yi1.li@intel.com>
Reviewed-by: Jiewen Yao <Jiewen.yao@intel.com>
2022-09-26 01:39:52 +00:00
..
Bn CryptoPkg: Add BigNum support 2022-09-23 10:08:24 +00:00
Cipher CryptoPkg: add AeadAesGcm support. 2022-09-23 08:24:42 +00:00
Hash CryptoPkg: Add SecCryptLib 2022-06-03 11:41:36 +00:00
Hmac CryptoPkg: Add HMAC-SHA384 cipher support. 2022-09-23 06:55:58 +00:00
Kdf CryptoPkg: add new Hkdf api in Crypt Lib. 2022-09-23 07:35:08 +00:00
Pem CryptoPkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
Pk CryptoPkg/BaseCryptLib:Remove redundant init 2022-09-23 00:36:29 +00:00
Rand CryptoPkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
SysCall CryptoPkg: Fix pem heap-buffer-overflow due to BIO_snprintf() 2022-09-26 01:39:52 +00:00
BaseCryptLib.inf CryptoPkg: Add BigNum support 2022-09-23 10:08:24 +00:00
BaseCryptLib.uni CryptoPkg: Replace BSD License with BSD+Patent License 2019-04-09 09:10:22 -07:00
InternalCryptLib.h CryptoPkg: Apply uncrustify changes 2021-12-07 17:24:28 +00:00
PeiCryptLib.inf CryptoPkg: Add BigNum support 2022-09-23 10:08:24 +00:00
PeiCryptLib.uni CryptoPkg/BaseCryptLib: Retire HMAC SHA1 algorithm 2020-05-15 07:22:36 +00:00
RuntimeCryptLib.inf CryptoPkg: add AeadAesGcm support. 2022-09-23 08:24:42 +00:00
RuntimeCryptLib.uni CryptoPkg/BaseCryptLib: Retire HMAC SHA1 algorithm 2020-05-15 07:22:36 +00:00
SecCryptLib.inf CryptoPkg: Update CryptLib inf as the file name changed. 2022-09-23 06:55:58 +00:00
SmmCryptLib.inf CryptoPkg: Add BigNum support 2022-09-23 10:08:24 +00:00
SmmCryptLib.uni CryptoPkg/BaseCryptLib: Retire HMAC SHA1 algorithm 2020-05-15 07:22:36 +00:00
UnitTestHostBaseCryptLib.inf CryptoPkg/Test: Add unit test for CryptoBn 2022-09-23 10:08:24 +00:00