aboutsummaryrefslogtreecommitdiffstats
path: root/url.c
diff options
context:
space:
mode:
authorIto Hiroyuki <ZXB01226@nifty.com>2010-07-20 00:09:34 +0000
committerIto Hiroyuki <ZXB01226@nifty.com>2010-07-20 00:09:34 +0000
commitc7da065f7f4a628f606d4610685df844d63e0e3d (patch)
tree8d3a6e0cd5e1493986e155a46b4f0524d687cc95 /url.c
parent* [w3m-dev 04321] Re: w3m's bugs from bugs.debian.org (diff)
downloadw3m-c7da065f7f4a628f606d4610685df844d63e0e3d.tar.gz
w3m-c7da065f7f4a628f606d4610685df844d63e0e3d.zip
* url.c (openSSLHandle): add support for TLS SNI (Server NameIndication)
Diffstat (limited to '')
-rw-r--r--url.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/url.c b/url.c
index e9fc59d..e6bf576 100644
--- a/url.c
+++ b/url.c
@@ -1,4 +1,4 @@
-/* $Id: url.c,v 1.96 2010/07/18 14:10:09 htrb Exp $ */
+/* $Id: url.c,v 1.97 2010/07/20 00:09:34 htrb Exp $ */
#include "fm.h"
#ifndef __MINGW32_VERSION
#include <sys/types.h>
@@ -375,6 +375,9 @@ openSSLHandle(int sock, char *hostname, char **p_cert)
#if SSLEAY_VERSION_NUMBER >= 0x00905100
init_PRNG();
#endif /* SSLEAY_VERSION_NUMBER >= 0x00905100 */
+#if (SSLEAY_VERSION_NUMBER >= 0x00908070) && !defined(OPENSSL_NO_TLSEXT)
+ SSL_set_tlsext_host_name(handle,hostname);
+#endif /* (SSLEAY_VERSION_NUMBER >= 0x00908070) && !defined(OPENSSL_NO_TLSEXT) */
if (SSL_connect(handle) > 0) {
Str serv_cert = ssl_get_certificate(handle, hostname);
if (serv_cert) {