mirror of
https://github.com/jwinterm/myriadcoin.git
synced 2026-11-27 11:44:02 +01:00
Disable SSLv3 (in favor of TLS) for the RPC client and server
sourced from https://github.com/bitcoin/bitcoin/commit/0a94661e8db94e84ecbf1ea45a51fb3c7fb77283
This commit is contained in:
+1
-1
@@ -40,7 +40,7 @@ Object CallRPC(const string& strMethod, const Array& params)
|
||||
bool fUseSSL = GetBoolArg("-rpcssl", false);
|
||||
asio::io_service io_service;
|
||||
ssl::context context(io_service, ssl::context::sslv23);
|
||||
context.set_options(ssl::context::no_sslv2);
|
||||
context.set_options(ssl::context::no_sslv2 | ssl::context::no_sslv3);
|
||||
asio::ssl::stream<asio::ip::tcp::socket> sslStream(io_service, context);
|
||||
SSLIOStreamDevice<asio::ip::tcp> d(sslStream, fUseSSL);
|
||||
iostreams::stream< SSLIOStreamDevice<asio::ip::tcp> > stream(d);
|
||||
|
||||
+1
-1
@@ -553,7 +553,7 @@ void StartRPCThreads()
|
||||
|
||||
if (fUseSSL)
|
||||
{
|
||||
rpc_ssl_context->set_options(ssl::context::no_sslv2);
|
||||
rpc_ssl_context->set_options(ssl::context::no_sslv2 | ssl::context::no_sslv3);
|
||||
|
||||
filesystem::path pathCertFile(GetArg("-rpcsslcertificatechainfile", "server.cert"));
|
||||
if (!pathCertFile.is_complete()) pathCertFile = filesystem::path(GetDataDir()) / pathCertFile;
|
||||
|
||||
Reference in New Issue
Block a user