Update whitelist

This commit is contained in:
Sefinek 2024-10-19 11:18:12 +02:00
parent e8e10ff51f
commit 9aad704ac1
2 changed files with 5 additions and 5 deletions

View file

@ -139,8 +139,7 @@ const reportIP = async (event, uri, country, hostname, endpoint, cycleErrorCount
continue; continue;
} }
const uri = `${event.clientRequestHTTPHost}${event.clientRequestPath}`; if (whitelist.includes(event.clientRequestPath)) return log('log', `Skipping ${event.clientRequestPath}...`);
if (whitelist.includes(uri)) return log('log', `Ignoring ${uri}...`);
const reportedIPs = readReportedIPs(); const reportedIPs = readReportedIPs();
const { recentlyReported, timeDifference, reason } = isIPReportedRecently(event.rayName, ip, reportedIPs); const { recentlyReported, timeDifference, reason } = isIPReportedRecently(event.rayName, ip, reportedIPs);
@ -165,7 +164,7 @@ const reportIP = async (event, uri, country, hostname, endpoint, cycleErrorCount
continue; continue;
} }
const wasReported = await reportIP(event, uri, event.clientCountryName, event.clientRequestHTTPHost, event.clientRequestPath, cycleErrorCounts); const wasReported = await reportIP(event, `${event.clientRequestHTTPHost}${event.clientRequestPath}`, event.clientCountryName, event.clientRequestHTTPHost, event.clientRequestPath, cycleErrorCounts);
if (wasReported) { if (wasReported) {
cycleReportedCount++; cycleReportedCount++;
await new Promise(resolve => setTimeout(resolve, SUCCESS_COOLDOWN)); await new Promise(resolve => setTimeout(resolve, SUCCESS_COOLDOWN));

View file

@ -1,4 +1,5 @@
module.exports = [ module.exports = [
'sefinek.net/milosna-grota/weryfikacja', '/weryfikacja',
'sefinek.net/genshin-stella-mod/download' '/verification',
'/download'
]; ];