[openssl-commits] [openssl] master update

Dr. Stephen Henson steve at openssl.org
Fri Aug 5 15:37:16 UTC 2016


The branch master has been updated
       via  3dc87806ce4517d58600b44975e14247cee1c807 (commit)
      from  684bc13e58c3c53b414a5a775b1118f04ad78bd7 (commit)


- Log -----------------------------------------------------------------
commit 3dc87806ce4517d58600b44975e14247cee1c807
Author: Dr. Stephen Henson <steve at openssl.org>
Date:   Fri Aug 5 16:06:36 2016 +0100

    Free buffer in a2i_ASN1_INTEGER() on error path.
    
    Thank to Shi Lei for reporting this bug.
    
    Reviewed-by: Rich Salz <rsalz at openssl.org>

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

Summary of changes:
 crypto/asn1/f_int.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/crypto/asn1/f_int.c b/crypto/asn1/f_int.c
index 0f16ac0..f1ed6bb 100644
--- a/crypto/asn1/f_int.c
+++ b/crypto/asn1/f_int.c
@@ -112,6 +112,7 @@ int a2i_ASN1_INTEGER(BIO *bp, ASN1_INTEGER *bs, char *buf, int size)
         i -= again;
         if (i % 2 != 0) {
             ASN1err(ASN1_F_A2I_ASN1_INTEGER, ASN1_R_ODD_NUMBER_OF_CHARS);
+            OPENSSL_free(s);
             return 0;
         }
         i /= 2;


More information about the openssl-commits mailing list