From 69039fd1fa3e65e2f5737b2a4044dcb8fbabb76d Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Fri, 23 Jun 2017 16:05:26 +0200 Subject: getinfo: access SSL internals via Curl_ssl In the ongoing endeavor to abstract out all SSL backend-specific functionality, this is the next step: Instead of hard-coding how the different SSL backends access their internal data in getinfo.c, let's implement backend-specific functions to do that task. This will also allow for switching SSL backends as a runtime option. Signed-off-by: Johannes Schindelin --- lib/vtls/schannel.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'lib/vtls/schannel.c') diff --git a/lib/vtls/schannel.c b/lib/vtls/schannel.c index d01a224c9..1296267ef 100644 --- a/lib/vtls/schannel.c +++ b/lib/vtls/schannel.c @@ -1773,6 +1773,13 @@ static CURLcode verify_certificate(struct connectdata *conn, int sockindex) } #endif /* _WIN32_WCE */ +static void *Curl_schannel_get_internals(struct ssl_connect_data *connssl, + CURLINFO info UNUSED_PARAM) +{ + (void)info; + return &connssl->ctxt->ctxt_handle; +} + const struct Curl_ssl Curl_ssl_schannel = { "schannel", /* name */ @@ -1792,6 +1799,7 @@ const struct Curl_ssl Curl_ssl_schannel = { Curl_none_cert_status_request, /* cert_status_request */ Curl_schannel_connect, /* connect */ Curl_schannel_connect_nonblocking, /* connect_nonblocking */ + Curl_schannel_get_internals, /* get_internals */ Curl_schannel_close, /* close */ Curl_none_close_all, /* close_all */ Curl_schannel_session_free, /* session_free */ -- cgit v1.2.3