From e8ea70776dc0902725b38d1f988fbadc40474d14 Mon Sep 17 00:00:00 2001 From: Johny Qiu Date: Fri, 11 Jun 2021 17:15:24 +0800 Subject: [PATCH] feat: use TLSv2 when TLS is used (#310) --- src/internal/sio_client_impl.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/internal/sio_client_impl.cpp b/src/internal/sio_client_impl.cpp index 1f91d5a9..8bf90f97 100644 --- a/src/internal/sio_client_impl.cpp +++ b/src/internal/sio_client_impl.cpp @@ -599,10 +599,9 @@ namespace sio #if SIO_TLS client_impl::context_ptr client_impl::on_tls_init(connection_hdl conn) { - context_ptr ctx = context_ptr(new asio::ssl::context(asio::ssl::context::tlsv1)); + context_ptr ctx = context_ptr(new asio::ssl::context(asio::ssl::context::tlsv12)); asio::error_code ec; ctx->set_options(asio::ssl::context::default_workarounds | - asio::ssl::context::no_sslv2 | asio::ssl::context::single_dh_use,ec); if(ec) {