diff options
author | Richard Levitte <levitte@openssl.org> | 2020-09-30 18:01:06 +0200 |
---|---|---|
committer | Richard Levitte <levitte@openssl.org> | 2020-10-04 13:23:03 +0200 |
commit | 6514dee7264d30be1ab9ab07f9798071184e7b7a (patch) | |
tree | 3970a529c35aa4df0aaa1d178cea2b9954319317 /apps/s_client.c | |
parent | 70c06aafa691a77861bd3d3aaf93afa2a55e04ce (diff) |
APPS: Reduce deprecation warning suppression - ENGINE
Some of our apps turn off deprecation warnings solely for the sake of
ENGINE, and thereby shadowing other deprecations that we should take
better care of.
To solve this, all apps ENGINE functionality is move to one file,
where deprecation warning suppression is activate, and the same
suppression can then easily be removed in at least some of the apps.
Any remaining suppression that we still need to deal with should
happen as separate efforts.
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/13044)
Diffstat (limited to 'apps/s_client.c')
-rw-r--r-- | apps/s_client.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/apps/s_client.c b/apps/s_client.c index 513beeaa9a..512ac0547b 100644 --- a/apps/s_client.c +++ b/apps/s_client.c @@ -8,9 +8,6 @@ * https://www.openssl.org/source/license.html */ -/* We need to use some engine deprecated APIs */ -#define OPENSSL_SUPPRESS_DEPRECATED - #include "e_os.h" #include <ctype.h> #include <stdio.h> @@ -1204,7 +1201,7 @@ int s_client_main(int argc, char **argv) break; case OPT_SSL_CLIENT_ENGINE: #ifndef OPENSSL_NO_ENGINE - ssl_client_engine = ENGINE_by_id(opt_arg()); + ssl_client_engine = setup_engine(opt_arg(), 0); if (ssl_client_engine == NULL) { BIO_printf(bio_err, "Error getting client auth engine\n"); goto opthelp; @@ -1881,10 +1878,10 @@ int s_client_main(int argc, char **argv) if (!SSL_CTX_set_client_cert_engine(ctx, ssl_client_engine)) { BIO_puts(bio_err, "Error setting client auth engine\n"); ERR_print_errors(bio_err); - ENGINE_free(ssl_client_engine); + release_engine(ssl_client_engine); goto end; } - ENGINE_free(ssl_client_engine); + release_engine(ssl_client_engine); } #endif |