|
|
|
@ -724,6 +724,13 @@ function handleMinerData(method, params, ip, portData, sendReply, pushMessage) {
|
|
|
|
|
}
|
|
|
|
|
job.submissions.push(params.nonce);
|
|
|
|
|
} else {
|
|
|
|
|
if (!Number.isInteger(params.poolNonce) || !Number.isInteger(params.workerNonce)) {
|
|
|
|
|
console.warn(threadName + 'Malformed nonce: ' + JSON.stringify(params) + ' from ' + miner.logString);
|
|
|
|
|
miner.checkBan(false);
|
|
|
|
|
sendReply('Duplicate share');
|
|
|
|
|
global.database.storeInvalidShare(miner.invalidShareProto);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
let nonce_test = `${params.nonce}_${params.poolNonce}_${params.workerNonce}`;
|
|
|
|
|
if (job.submissions.indexOf(nonce_test) !== -1) {
|
|
|
|
|
console.warn(threadName + 'Duplicate share: ' + JSON.stringify(params) + ' from ' + miner.logString);
|
|
|
|
|