[openssl] master update

tomas at openssl.org tomas at openssl.org
Fri Jan 28 14:07:10 UTC 2022


The branch master has been updated
       via  4dd085c03a885580cc945f71187131ea7fb39b70 (commit)
      from  7f1cb465c1f0e45bde8c1ee54a37e6f7641c70c6 (commit)


- Log -----------------------------------------------------------------
commit 4dd085c03a885580cc945f71187131ea7fb39b70
Author: Zhou Qingyang <zhou1615 at umn.edu>
Date:   Tue Jan 25 01:37:59 2022 +0800

    Add the missing check of BN_bn2hex return value
    
    CLA: trivial
    
    Signed-off-by: Zhou Qingyang <zhou1615 at umn.edu>
    
    Reviewed-by: Paul Dale <pauli at openssl.org>
    Reviewed-by: Matt Caswell <matt at openssl.org>
    Reviewed-by: Tomas Mraz <tomas at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/17578)

-----------------------------------------------------------------------

Summary of changes:
 providers/implementations/encode_decode/encode_key2text.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/providers/implementations/encode_decode/encode_key2text.c b/providers/implementations/encode_decode/encode_key2text.c
index f8f9712e96..9455f97c4a 100644
--- a/providers/implementations/encode_decode/encode_key2text.c
+++ b/providers/implementations/encode_decode/encode_key2text.c
@@ -80,6 +80,9 @@ static int print_labeled_bignum(BIO *out, const char *label, const BIGNUM *bn)
     }
 
     hex_str = BN_bn2hex(bn);
+    if (hex_str == NULL)
+        return 0;
+
     p = hex_str;
     if (*p == '-') {
         ++p;


More information about the openssl-commits mailing list