From: Alan T. DeKok Date: Fri, 14 Apr 2023 14:56:11 +0000 (-0400) Subject: use TLS_method() X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=24dbb68c2c10ba066c1f2283ec17df138e5a700d;p=thirdparty%2Ffreeradius-server.git use TLS_method() as per https://www.openssl.org/docs/man3.1/man3/TLS_method.html --- diff --git a/src/lib/tls/base-h b/src/lib/tls/base-h index c518e95df6..13326d5012 100644 --- a/src/lib/tls/base-h +++ b/src/lib/tls/base-h @@ -104,7 +104,7 @@ extern _Thread_local TALLOC_CTX *ssl_talloc_ctx; * so will free the allocated object last, after doing manual cleanups. * @code{.c} - FR_OPENSSL_BIND_MEMORY(ctx = SSL_CTX_new(SSLv23_method())); + FR_OPENSSL_BIND_MEMORY(ctx = SSL_CTX_new(TLS_method())); if (!ctx) ..error @endcode * @param _expr The call to the OpenSSL function and storage of the diff --git a/src/lib/tls/ctx.c b/src/lib/tls/ctx.c index afb44a2741..0da2685cbe 100644 --- a/src/lib/tls/ctx.c +++ b/src/lib/tls/ctx.c @@ -615,7 +615,7 @@ SSL_CTX *fr_tls_ctx_alloc(fr_tls_conf_t const *conf, bool client) int verify_mode = SSL_VERIFY_NONE; int ctx_options = 0; - ctx = SSL_CTX_new(SSLv23_method()); + ctx = SSL_CTX_new(TLS_method()); if (!ctx) { fr_tls_log(NULL, "Failed creating TLS context"); return NULL;