diff options
author | Jung-uk Kim <jkim@FreeBSD.org> | 2018-11-20 18:59:41 +0000 |
---|---|---|
committer | Jung-uk Kim <jkim@FreeBSD.org> | 2018-11-20 18:59:41 +0000 |
commit | 8c3f9abd70b3f447a4795c1b00b386b044fb322d (patch) | |
tree | 884976f2693f42bade35b92edc3c1f7f8c53825b /apps/rsa.c | |
parent | a43ce912fc025d11e1395506111f75fc194d7ba5 (diff) |
Diffstat (limited to 'apps/rsa.c')
-rw-r--r-- | apps/rsa.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/apps/rsa.c b/apps/rsa.c index 6458b3d9c5aa..fdd02dce3241 100644 --- a/apps/rsa.c +++ b/apps/rsa.c @@ -38,8 +38,8 @@ typedef enum OPTION_choice { const OPTIONS rsa_options[] = { {"help", OPT_HELP, '-', "Display this summary"}, - {"inform", OPT_INFORM, 'f', "Input format, one of DER NET PEM"}, - {"outform", OPT_OUTFORM, 'f', "Output format, one of DER NET PEM PVK"}, + {"inform", OPT_INFORM, 'f', "Input format, one of DER PEM"}, + {"outform", OPT_OUTFORM, 'f', "Output format, one of DER PEM PVK"}, {"in", OPT_IN, 's', "Input file"}, {"out", OPT_OUT, '>', "Output file"}, {"pubin", OPT_PUBIN, '-', "Expect a public key in input file"}, @@ -269,6 +269,9 @@ int rsa_main(int argc, char **argv) } else if (outformat == FORMAT_MSBLOB || outformat == FORMAT_PVK) { EVP_PKEY *pk; pk = EVP_PKEY_new(); + if (pk == NULL) + goto end; + EVP_PKEY_set1_RSA(pk, rsa); if (outformat == FORMAT_PVK) { if (pubin) { |