[openssl] master update

matthias.st.pierre at ncp-e.com matthias.st.pierre at ncp-e.com
Sun Oct 20 21:59:04 UTC 2019


The branch master has been updated
       via  5e58733b23fd33f526fb95ae636daf7ebf023359 (commit)
      from  de1581988f4a6b6e25f1e01474c63dc55f004c2a (commit)


- Log -----------------------------------------------------------------
commit 5e58733b23fd33f526fb95ae636daf7ebf023359
Author: Dr. Matthias St. Pierre <Matthias.St.Pierre at ncp-e.com>
Date:   Sun Oct 20 13:10:38 2019 +0200

    ciphers/chacha20,poly1303: Fix two coverity errors
    
    CID 1454872, 1454873:  Incorrect expression  (SIZEOF_MISMATCH)
    
    Reviewed-by: Richard Levitte <levitte at openssl.org>
    (Merged from https://github.com/openssl/openssl/pull/10223)

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

Summary of changes:
 providers/implementations/ciphers/cipher_chacha20.c          | 2 +-
 providers/implementations/ciphers/cipher_chacha20_poly1305.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/providers/implementations/ciphers/cipher_chacha20.c b/providers/implementations/ciphers/cipher_chacha20.c
index 7cc57e7043..d92fa08d0c 100644
--- a/providers/implementations/ciphers/cipher_chacha20.c
+++ b/providers/implementations/ciphers/cipher_chacha20.c
@@ -55,7 +55,7 @@ static void chacha20_freectx(void *vctx)
     PROV_CHACHA20_CTX *ctx = (PROV_CHACHA20_CTX *)vctx;
 
     if (ctx != NULL) {
-        OPENSSL_clear_free(ctx, sizeof(ctx));
+        OPENSSL_clear_free(ctx, sizeof(*ctx));
     }
 }
 
diff --git a/providers/implementations/ciphers/cipher_chacha20_poly1305.c b/providers/implementations/ciphers/cipher_chacha20_poly1305.c
index cc702cb8fc..b92d8d545e 100644
--- a/providers/implementations/ciphers/cipher_chacha20_poly1305.c
+++ b/providers/implementations/ciphers/cipher_chacha20_poly1305.c
@@ -66,7 +66,7 @@ static void chacha20_poly1305_freectx(void *vctx)
     PROV_CHACHA20_POLY1305_CTX *ctx = (PROV_CHACHA20_POLY1305_CTX *)vctx;
 
     if (ctx != NULL)
-        OPENSSL_clear_free(ctx, sizeof(ctx));
+        OPENSSL_clear_free(ctx, sizeof(*ctx));
 }
 
 static int chacha20_poly1305_get_params(OSSL_PARAM params[])


More information about the openssl-commits mailing list