diff options
author | Rich Salz <rsalz@akamai.com> | 2021-02-08 14:03:35 -0500 |
---|---|---|
committer | Pauli <ppzgs1@gmail.com> | 2021-02-12 08:34:17 +1000 |
commit | d0190e11639956677747f6bc7bb5bcd610fd8600 (patch) | |
tree | 65b3b8fa880bd32563f4e59bc82624489673da6d /apps/enc.c | |
parent | 51e5df0ed01efa47335940425cc8744ecff1b6ae (diff) | |
download | openssl-new-d0190e11639956677747f6bc7bb5bcd610fd8600.tar.gz |
Process digest option after loading providers
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14135)
Diffstat (limited to 'apps/enc.c')
-rw-r--r-- | apps/enc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/enc.c b/apps/enc.c index 4549895b9e..9982337c01 100644 --- a/apps/enc.c +++ b/apps/enc.c @@ -111,7 +111,7 @@ int enc_main(int argc, char **argv) EVP_CIPHER_CTX *ctx = NULL; const EVP_CIPHER *cipher = NULL; const EVP_MD *dgst = NULL; - const char *dgstname = NULL; + const char *digestname = NULL; char *hkey = NULL, *hiv = NULL, *hsalt = NULL, *p; char *infile = NULL, *outfile = NULL, *prog; char *str = NULL, *passarg = NULL, *pass = NULL, *strbuf = NULL; @@ -260,7 +260,7 @@ int enc_main(int argc, char **argv) hiv = opt_arg(); break; case OPT_MD: - dgstname = opt_arg(); + digestname = opt_arg(); break; case OPT_CIPHER: ciphername = opt_unknown(); @@ -308,8 +308,8 @@ int enc_main(int argc, char **argv) BIO_printf(bio_err, "%s XTS ciphers not supported\n", prog); goto end; } - if (dgstname != NULL) { - if (!!opt_md(opt_arg(), &dgst)) + if (digestname != NULL) { + if (!opt_md(digestname, &dgst)) goto opthelp; } if (dgst == NULL) |