From c79ed7cf4cf9fb747ac793efb827a769028a1d7e Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Thu, 9 Feb 2017 01:47:54 +0100 Subject: [PATCH] TLSClient: Removed test code --- src/TLSClient.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/TLSClient.cpp b/src/TLSClient.cpp index 8feca6ea9..b276627bd 100644 --- a/src/TLSClient.cpp +++ b/src/TLSClient.cpp @@ -210,14 +210,6 @@ void TLSClient::connect (const std::string& host, const std::string& port) gnutls_session_set_verify_cert (_session, _host.c_str (), 0); // 3.4.6 #endif - // SNI. Only permitted when _host is a DNS name, not an IPv4/6 address. - if (_host.find_first_not_of ("0123456789abcdefABCDEF:.") != std::string::npos) - { - ret = gnutls_server_name_set (_session, GNUTLS_NAME_DNS, _host.c_str (), _host.length ()); // All - if (ret < 0) - throw format ("TLS SNI error. {1}", gnutls_strerror (ret)); // All - } - // Store the TLSClient instance, so that the verification callback can access // it during the handshake below and call the verification method. gnutls_session_set_ptr (_session, (void*) this); // All