diff options
author | Petr Gotthard <petr.gotthard@centrum.cz> | 2020-12-26 21:32:14 +0100 |
---|---|---|
committer | Pauli <ppzgs1@gmail.com> | 2021-02-05 10:24:04 +1000 |
commit | 7dc67708c8ae6ec06c7fec34781225ed60b5e68d (patch) | |
tree | c48ecd0e6c3a24a5837a09a7e7497c458052d4c6 /apps/mac.c | |
parent | 88444854affe31ce08a5daaf4b6afc86e6972c63 (diff) |
apps/openssl: add -propquery command line option
Fixes #13656. Right now all openssl commands use a NULL propq. This
patch adds a possibility to specify a custom propq.
The implementation follows the example of set_nameopt/get_nameopt.
Various tools had to be modified to call app_get0_propq after it has
been populated. Otherwise the -propquery has no effect.
The tests then verify the -propquery affects the tool behaviour by
requesting a non-existing property.
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/13707)
Diffstat (limited to 'apps/mac.c')
-rw-r--r-- | apps/mac.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/mac.c b/apps/mac.c index ea75b33623..ce00ff92e0 100644 --- a/apps/mac.c +++ b/apps/mac.c @@ -105,7 +105,7 @@ opthelp: if (argc != 1) goto opthelp; - mac = EVP_MAC_fetch(NULL, argv[0], NULL); + mac = EVP_MAC_fetch(app_get0_libctx(), argv[0], app_get0_propq()); if (mac == NULL) { BIO_printf(bio_err, "Invalid MAC name %s\n", argv[0]); goto opthelp; |