From bcc31778e3695e23d7c4cd6274126a8e3d58db72 Mon Sep 17 00:00:00 2001 From: Matt Caswell Date: Fri, 15 Apr 2016 14:42:48 +0100 Subject: Add missing return value check in pkcs8 app Reviewed-by: Richard Levitte --- apps/pkcs8.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/pkcs8.c b/apps/pkcs8.c index 15b8e6a084..cd4e76b6d0 100644 --- a/apps/pkcs8.c +++ b/apps/pkcs8.c @@ -341,7 +341,10 @@ int pkcs8_main(int argc, char **argv) else if (1) { #ifndef OPENSSL_NO_UI p8pass = pass; - EVP_read_pw_string(pass, sizeof pass, "Enter Password:", 0); + if (EVP_read_pw_string(pass, sizeof pass, "Enter Password:", 0)) { + BIO_printf(bio_err, "Can't read Password\n"); + goto end; + } } else { #endif BIO_printf(bio_err, "Password required\n"); -- cgit v1.2.3