From 7f7f66a1f1c694daab2b1359e45b9eff7d255f46 Mon Sep 17 00:00:00 2001 From: filimonov <1549571+filimonov@users.noreply.github.com> Date: Fri, 13 Nov 2020 17:45:58 +0100 Subject: [PATCH] add comment & restart CI... --- src/Client/Connection.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Client/Connection.cpp b/src/Client/Connection.cpp index b810d24b3d3..0a499540c41 100644 --- a/src/Client/Connection.cpp +++ b/src/Client/Connection.cpp @@ -73,6 +73,10 @@ void Connection::connect(const ConnectionTimeouts & timeouts) { #if USE_SSL socket = std::make_unique(); + + /// we resolve the ip when we open SecureStreamSocket, so to make Server Name Indication (SNI) + /// work we need to pass host name separately. It will be send into TLS Hello packet to let + /// the server know which host we want to talk with (single IP can process requests for multiple hosts using SNI). static_cast(socket.get())->setPeerHostName(host); #else throw Exception{"tcp_secure protocol is disabled because poco library was built without NetSSL support.", ErrorCodes::SUPPORT_IS_DISABLED};