aboutsummaryrefslogtreecommitdiff
path: root/contrib/epee/include/net/net_helper.h
diff options
context:
space:
mode:
authorLee Clagett <code@leeclagett.com>2019-03-19 16:04:32 -0400
committerLee Clagett <code@leeclagett.com>2019-04-07 00:44:37 -0400
commiteca0fea45a1fe2eb359c6fff5f5701e0b2fcdc5a (patch)
treedcd4b88bee4974e03ea82f667d7cfa45cee55df7 /contrib/epee/include/net/net_helper.h
parentRequire server verification when SSL is enabled. (diff)
downloadmonero-eca0fea45a1fe2eb359c6fff5f5701e0b2fcdc5a.tar.xz
Perform RFC 2818 hostname verification in client SSL handshakes
If the verification mode is `system_ca`, clients will now do hostname verification. Thus, only certificates from expected hostnames are allowed when SSL is enabled. This can be overridden by forcible setting the SSL mode to autodetect. Clients will also send the hostname even when `system_ca` is not being performed. This leaks possible metadata, but allows servers providing multiple hostnames to respond with the correct certificate. One example is cloudflare, which getmonero.org is currently using.
Diffstat (limited to 'contrib/epee/include/net/net_helper.h')
-rw-r--r--contrib/epee/include/net/net_helper.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/epee/include/net/net_helper.h b/contrib/epee/include/net/net_helper.h
index a9bfd6baa..66a307c97 100644
--- a/contrib/epee/include/net/net_helper.h
+++ b/contrib/epee/include/net/net_helper.h
@@ -174,7 +174,7 @@ namespace net_utils
// SSL Options
if (ssl_support == epee::net_utils::ssl_support_t::e_ssl_support_enabled || ssl_support == epee::net_utils::ssl_support_t::e_ssl_support_autodetect)
{
- if (!m_ssl_options.handshake(*m_ssl_socket, boost::asio::ssl::stream_base::client))
+ if (!m_ssl_options.handshake(*m_ssl_socket, boost::asio::ssl::stream_base::client, addr))
{
if (ssl_support == epee::net_utils::ssl_support_t::e_ssl_support_autodetect)
{