TLS: Set SNI hostname before connect

This commit is contained in:
moparisthebest 2015-09-11 01:48:29 -04:00
parent 73636a00b5
commit dbad9285b8
1 changed files with 4 additions and 0 deletions

View File

@ -487,6 +487,10 @@ ssl_do_connect (server * serv)
char buf[128]; char buf[128];
g_sess = serv->server_session; 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) if (SSL_connect (serv->ssl) <= 0)
{ {
char err_buf[128]; char err_buf[128];