Skip to content

Commit 38bcd58

Browse files
committed
Chore: Update Phishing Hosts Score
1 parent 8a36379 commit 38bcd58

File tree

1 file changed

+18
-13
lines changed

1 file changed

+18
-13
lines changed

Build/lib/get-phishing-domains.ts

+18-13
Original file line numberDiff line numberDiff line change
@@ -185,14 +185,15 @@ const processPhihsingDomains = cache(function processPhihsingDomains(domainArr:
185185
|| (domainScoreMap[apexDomain] >= 13 && count >= 11)
186186
|| (domainScoreMap[apexDomain] >= 5 && count >= 14)
187187
|| (domainScoreMap[apexDomain] >= 3 && count >= 21)
188+
|| (domainScoreMap[apexDomain] >= 1 && count >= 60)
188189
) {
189190
domainArr.push('.' + apexDomain);
190191
}
191192
});
192193

193194
// console.log({
194-
// score: domainScoreMap['flk-ipfs.xyz'],
195-
// count: domainCountMap.get('flk-ipfs.xyz')
195+
// score: domainScoreMap['awicksin.com'],
196+
// count: domainCountMap.get('awicksin.com')
196197
// });
197198

198199
// console.log({ duplicateCount, domainArrLen: domainArr.length });
@@ -247,20 +248,24 @@ export function calcDomainAbuseScore(subdomain: string, fullDomain: string = sub
247248

248249
const subdomainLength = subdomain.length;
249250

250-
if (subdomainLength > 13) {
251-
weight += 0.2;
252-
if (subdomainLength > 20) {
253-
weight += 1;
254-
if (subdomainLength > 30) {
255-
weight += 5;
256-
if (subdomainLength > 40) {
257-
weight += 10;
251+
if (subdomainLength > 6) {
252+
weight += 0.015;
253+
254+
if (subdomainLength > 13) {
255+
weight += 0.2;
256+
if (subdomainLength > 20) {
257+
weight += 1;
258+
if (subdomainLength > 30) {
259+
weight += 5;
260+
if (subdomainLength > 40) {
261+
weight += 10;
262+
}
258263
}
259264
}
260-
}
261265

262-
if (subdomain.indexOf('.', 1) > 1) {
263-
weight += 1;
266+
if (subdomain.indexOf('.', 1) > 1) {
267+
weight += 1;
268+
}
264269
}
265270
}
266271

0 commit comments

Comments
 (0)