openssl/crypto/ui
Darshan Sen 59ccb72cd5 Fix invalid malloc failures in PEM_write_bio_PKCS8PrivateKey()
When `PEM_write_bio_PKCS8PrivateKey()` was passed an empty passphrase
string, `OPENSSL_memdup()` was incorrectly getting used for 0 bytes size
allocation, which resulted in malloc failures.

Fixes: https://github.com/openssl/openssl/issues/17506

Signed-off-by: Darshan Sen <raisinten@gmail.com>

Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/17507)
2022-01-26 17:15:52 +01:00
..
build.info
ui_err.c
ui_lib.c Update copyright year 2021-07-29 15:41:35 +01:00
ui_local.h
ui_null.c
ui_openssl.c close_console: Always unlock as the lock is always held 2022-01-03 10:57:39 +01:00
ui_util.c Fix invalid malloc failures in PEM_write_bio_PKCS8PrivateKey() 2022-01-26 17:15:52 +01:00