mirror of
https://github.com/socketio/socket.io-client-cpp.git
synced 2026-05-06 14:02:56 +00:00
feat: support TLSv1.2 and newer (#321)
This commit is contained in:
parent
e8ea70776d
commit
82d39a90ef
@ -599,10 +599,12 @@ failed:
|
||||
#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::tlsv12));
|
||||
context_ptr ctx = context_ptr(new asio::ssl::context(asio::ssl::context::tls));
|
||||
asio::error_code ec;
|
||||
ctx->set_options(asio::ssl::context::default_workarounds |
|
||||
asio::ssl::context::single_dh_use,ec);
|
||||
asio::ssl::context::no_tlsv1 |
|
||||
asio::ssl::context::no_tlsv1_1 |
|
||||
asio::ssl::context::single_dh_use,ec);
|
||||
if(ec)
|
||||
{
|
||||
cerr<<"Init tls failed,reason:"<< ec.message()<<endl;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user