From dbad9285b8a4267cc7e7e3c3fd84699ed406a13a Mon Sep 17 00:00:00 2001 From: moparisthebest Date: Fri, 11 Sep 2015 01:48:29 -0400 Subject: TLS: Set SNI hostname before connect --- src/common/server.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/common/server.c b/src/common/server.c index 62ba9540..8ff81553 100644 --- a/src/common/server.c +++ b/src/common/server.c @@ -487,6 +487,10 @@ ssl_do_connect (server * serv) char buf[128]; g_sess = serv->server_session; + + /* Set SNI hostname before connect */ + SSL_set_tlsext_host_name(serv->ssl, serv->hostname); + if (SSL_connect (serv->ssl) <= 0) { char err_buf[128]; -- cgit 1.4.1