mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Auto-TLS support.
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
namespace websocketpp
|
||||
{
|
||||
class server;
|
||||
class server_tls;
|
||||
class server_autotls;
|
||||
}
|
||||
|
||||
#endif
|
||||
@@ -20,19 +20,18 @@ namespace websocketpp
|
||||
class WSDoor
|
||||
{
|
||||
private:
|
||||
websocketpp::server* mEndpoint;
|
||||
websocketpp::server_tls* mSEndpoint;
|
||||
websocketpp::server_autotls* mSEndpoint;
|
||||
|
||||
boost::thread* mThread;
|
||||
bool mPublic;
|
||||
std::string mIp;
|
||||
int mPort;
|
||||
boost::thread* mThread;
|
||||
bool mPublic;
|
||||
std::string mIp;
|
||||
int mPort;
|
||||
|
||||
void startListening();
|
||||
|
||||
public:
|
||||
|
||||
WSDoor(const std::string& strIp, int iPort, bool bPublic) : mEndpoint(0), mSEndpoint(0), mThread(0), mPublic(bPublic), mIp(strIp), mPort(iPort) { ; }
|
||||
WSDoor(const std::string& strIp, int iPort, bool bPublic) : mSEndpoint(0), mThread(0), mPublic(bPublic), mIp(strIp), mPort(iPort) { ; }
|
||||
|
||||
void stop();
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ protected:
|
||||
public:
|
||||
WSServerHandler(boost::shared_ptr<boost::asio::ssl::context> spCtx, bool bPublic) : mCtx(spCtx), mPublic(bPublic)
|
||||
{
|
||||
if (theConfig.WEBSOCKET_SECURE)
|
||||
if (theConfig.WEBSOCKET_SECURE != 0)
|
||||
{
|
||||
initSSLContext(*mCtx, theConfig.WEBSOCKET_SSL_KEY,
|
||||
theConfig.WEBSOCKET_SSL_CERT, theConfig.WEBSOCKET_SSL_CHAIN);
|
||||
|
||||
Reference in New Issue
Block a user