mirror of
https://github.com/xmrig/xmrig.git
synced 2024-11-05 16:07:42 +00:00
New donations proxy addresses with SSL/TLS support.
This commit is contained in:
parent
0d9db273a0
commit
0d197f8906
2 changed files with 8 additions and 18 deletions
|
@ -33,10 +33,6 @@
|
||||||
#include "net/strategies/DonateStrategy.h"
|
#include "net/strategies/DonateStrategy.h"
|
||||||
|
|
||||||
|
|
||||||
const static char *kDonatePool1 = "miner.fee.xmrig.com";
|
|
||||||
const static char *kDonatePool2 = "emergency.fee.xmrig.com";
|
|
||||||
|
|
||||||
|
|
||||||
static inline float randomf(float min, float max) {
|
static inline float randomf(float min, float max) {
|
||||||
return (max - min) * ((((float) rand()) / (float) RAND_MAX)) + min;
|
return (max - min) * ((((float) rand()) / (float) RAND_MAX)) + min;
|
||||||
}
|
}
|
||||||
|
@ -55,17 +51,11 @@ DonateStrategy::DonateStrategy(int level, const char *user, xmrig::Algo algo, IS
|
||||||
xmrig::keccak(reinterpret_cast<const uint8_t *>(user), strlen(user), hash);
|
xmrig::keccak(reinterpret_cast<const uint8_t *>(user), strlen(user), hash);
|
||||||
Job::toHex(hash, 32, userId);
|
Job::toHex(hash, 32, userId);
|
||||||
|
|
||||||
if (algo == xmrig::CRYPTONIGHT) {
|
# ifndef XMRIG_NO_TLS
|
||||||
m_pools.push_back(Pool(kDonatePool1, 6666, userId, nullptr, false, true));
|
m_pools.push_back(Pool("donate.ssl.xmrig.com", 443, userId, nullptr, false, true, true));
|
||||||
m_pools.push_back(Pool(kDonatePool1, 80, userId, nullptr, false, true));
|
# endif
|
||||||
m_pools.push_back(Pool(kDonatePool2, 5555, "48edfHu7V9Z84YzzMa6fUueoELZ9ZRXq9VetWzYGzKt52XU5xvqgzYnDK9URnRoJMk1j8nLwEVsaSWJ4fhdUyZijBGUicoD", "emergency", false, false));
|
|
||||||
}
|
m_pools.push_back(Pool("donate.v2.xmrig.com", 3333, userId, nullptr, false, true));
|
||||||
else if (algo == xmrig::CRYPTONIGHT_HEAVY) {
|
|
||||||
m_pools.push_back(Pool(kDonatePool1, 8888, userId, nullptr, false, true));
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
m_pools.push_back(Pool(kDonatePool1, 5555, userId, nullptr, false, true));
|
|
||||||
}
|
|
||||||
|
|
||||||
for (Pool &pool : m_pools) {
|
for (Pool &pool : m_pools) {
|
||||||
pool.adjust(xmrig::Algorithm(algo, xmrig::VARIANT_AUTO));
|
pool.adjust(xmrig::Algorithm(algo, xmrig::VARIANT_AUTO));
|
||||||
|
|
|
@ -21,8 +21,8 @@
|
||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef __DONATESTRATEGY_H__
|
#ifndef XMRIG_DONATESTRATEGY_H
|
||||||
#define __DONATESTRATEGY_H__
|
#define XMRIG_DONATESTRATEGY_H
|
||||||
|
|
||||||
|
|
||||||
#include <uv.h>
|
#include <uv.h>
|
||||||
|
@ -76,4 +76,4 @@ private:
|
||||||
uv_timer_t m_timer;
|
uv_timer_t m_timer;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif /* __DONATESTRATEGY_H__ */
|
#endif /* XMRIG_DONATESTRATEGY_H */
|
||||||
|
|
Loading…
Reference in a new issue