mirror of
https://github.com/xmrig/xmrig.git
synced 2025-12-27 06:20:51 -05:00
This commit is contained in:
@@ -293,7 +293,7 @@ void xmrig::Client::tick(uint64_t now)
|
||||
}
|
||||
|
||||
if (m_state == ConnectingState && m_expire && now > m_expire) {
|
||||
return reconnect();
|
||||
close();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -744,6 +744,7 @@ void xmrig::Client::parseExtensions(const rapidjson::Value &result)
|
||||
}
|
||||
else if (strcmp(name, "keepalive") == 0) {
|
||||
setExtension(EXT_KEEPALIVE, true);
|
||||
startTimeout();
|
||||
}
|
||||
# ifdef XMRIG_FEATURE_TLS
|
||||
else if (strcmp(name, "tls") == 0) {
|
||||
@@ -974,7 +975,7 @@ void xmrig::Client::onConnect(uv_connect_t *req, int status)
|
||||
LOG_ERR("[%s] connect error: \"%s\"", client->url(), uv_strerror(status));
|
||||
}
|
||||
|
||||
if (client->state() == ReconnectingState) {
|
||||
if (client->state() == ReconnectingState || client->state() == ClosingState) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -991,7 +992,7 @@ void xmrig::Client::onConnect(uv_connect_t *req, int status)
|
||||
}
|
||||
|
||||
if (client->state() == ConnectedState) {
|
||||
LOG_ERR("[%s] already connected");
|
||||
LOG_ERR("[%s] already connected", client->url());
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -156,7 +156,7 @@ bool xmrig::TlsContext::load(const TlsConfig &config)
|
||||
SSL_CTX_set_options(m_ctx, SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3);
|
||||
SSL_CTX_set_options(m_ctx, SSL_OP_CIPHER_SERVER_PREFERENCE);
|
||||
|
||||
# if OPENSSL_VERSION_NUMBER >= 0x1010100fL
|
||||
# if OPENSSL_VERSION_NUMBER >= 0x1010100fL && !defined(LIBRESSL_VERSION_NUMBER)
|
||||
SSL_CTX_set_max_early_data(m_ctx, 0);
|
||||
# endif
|
||||
|
||||
@@ -184,7 +184,7 @@ bool xmrig::TlsContext::setCipherSuites(const char *ciphersuites)
|
||||
return true;
|
||||
}
|
||||
|
||||
# if OPENSSL_VERSION_NUMBER >= 0x1010100fL
|
||||
# if OPENSSL_VERSION_NUMBER >= 0x1010100fL && !defined(LIBRESSL_VERSION_NUMBER)
|
||||
if (SSL_CTX_set_ciphersuites(m_ctx, ciphersuites) == 1) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user