From 9805bb1bdb8dad4c58725cb25766fc7593e08098 Mon Sep 17 00:00:00 2001 From: Ben Greear Date: Tue, 12 Sep 2017 10:43:36 -0700 Subject: [PATCH] HTTP (curl): Use SSL_get_SSL_CTX() helper The direct ssl->ctx access are not allowed anymore in newer OpenSSL versions, so use the SSL_get_SSL_CTX() helper for this. Signed-off-by: Ben Greear --- src/utils/http_curl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/utils/http_curl.c b/src/utils/http_curl.c index 58519ea8d..3fd8e424a 100644 --- a/src/utils/http_curl.c +++ b/src/utils/http_curl.c @@ -1136,7 +1136,7 @@ static int ocsp_resp_cb(SSL *s, void *arg) return 0; } - store = SSL_CTX_get_cert_store(s->ctx); + store = SSL_CTX_get_cert_store(SSL_get_SSL_CTX(s)); if (ctx->peer_issuer) { wpa_printf(MSG_DEBUG, "OpenSSL: Add issuer"); debug_dump_cert("OpenSSL: Issuer certificate", @@ -1277,7 +1277,7 @@ static const SSL_METHOD *real_ssl_method; static int curl_patch_ssl_new(SSL *s) { - SSL_CTX *ssl = s->ctx; + SSL_CTX *ssl = SSL_get_SSL_CTX(s); int ret; ssl->method = real_ssl_method;