Skip to content

Commit d5a8358

Browse files
authored
Merge pull request #9 from ClickHouse/ClickHouse/fix-msan-p12_decr
Zero out memory after allocation to avoid usage of uninitialized memory
2 parents 65e279b + 3a10ccf commit d5a8358

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crypto/pkcs12/p12_decr.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ unsigned char *PKCS12_pbe_crypt_ex(const X509_ALGOR *algor,
7575
}
7676
}
7777

78-
if ((out = OPENSSL_malloc(max_out_len)) == NULL)
78+
if ((out = OPENSSL_zalloc(max_out_len)) == NULL)
7979
goto err;
8080

8181
if (!EVP_CipherUpdate(ctx, out, &i, in, inlen)) {

0 commit comments

Comments
 (0)