瀏覽代碼

Housekeeping & Minor changes

SukkaW 1 年之前
父節點
當前提交
2fbbfd2d93
共有 4 個文件被更改,包括 7 次插入49 次删除
  1. 0 28
      Build/lib/get-phishing-domains.test.ts
  2. 0 14
      Build/lib/stable-sort-domain.bench.ts
  3. 2 2
      package.json
  4. 5 5
      pnpm-lock.yaml

+ 0 - 28
Build/lib/get-phishing-domains.test.ts

@@ -1,28 +0,0 @@
-import { describe, it } from 'mocha';
-
-import { calcDomainAbuseScore } from './get-phishing-domains';
-
-describe('sortDomains', () => {
-  it('nmdj.pl', () => {
-    console.log(calcDomainAbuseScore('.booking-com'));
-    console.log(calcDomainAbuseScore('plikgier'));
-    console.log(calcDomainAbuseScore('www.addgumtree'));
-    console.log(calcDomainAbuseScore('zrz'));
-    console.log(calcDomainAbuseScore('z1'));
-    console.log(calcDomainAbuseScore('accountsettingaddrecoverymanagesiteupdatebillingreview.village'));
-    console.log(calcDomainAbuseScore('allegrolokalnie'));
-  });
-
-  it('zendesk.com', () => {
-    console.log(calcDomainAbuseScore('binomo2'));
-    console.log(calcDomainAbuseScore('www.binomo2'));
-    console.log(calcDomainAbuseScore('store.binomo2'));
-    console.log(calcDomainAbuseScore('gimp'));
-    console.log(calcDomainAbuseScore('store.gimp'));
-    console.log(calcDomainAbuseScore('www.gimp'));
-  });
-
-  it('digital-marketing-insights.icu', () => {
-    console.log(calcDomainAbuseScore('ovusc7pijit9'));
-  });
-});

+ 0 - 14
Build/lib/stable-sort-domain.bench.ts

@@ -1,14 +0,0 @@
-import { fetchRemoteTextByLine } from './fetch-text-by-line';
-import { sortDomains } from './stable-sort-domain';
-
-import { bench, group, run } from 'mitata';
-
-(async () => {
-  const data = await Array.fromAsync(await fetchRemoteTextByLine('https://osint.digitalside.it/Threat-Intel/lists/latestdomains.txt', true));
-
-  group(() => {
-    bench('sortDomains', () => sortDomains(data));
-  });
-
-  run();
-})();

+ 2 - 2
package.json

@@ -31,7 +31,7 @@
     "fast-cidr-tools": "^0.3.2",
     "fast-fifo": "^1.3.2",
     "fdir": "^6.4.3",
-    "foxts": "^2.0.1",
+    "foxts": "^3.0.0",
     "hash-wasm": "^4.12.0",
     "json-stringify-pretty-compact": "3.0.0",
     "picocolors": "^1.1.1",
@@ -68,7 +68,7 @@
     "mocha": "^11.1.0",
     "typescript": "^5.8.2"
   },
-  "packageManager": "pnpm@10.6.4",
+  "packageManager": "pnpm@10.6.5",
   "pnpm": {
     "patchedDependencies": {
       "whoiser": "patches/whoiser.patch"

+ 5 - 5
pnpm-lock.yaml

@@ -50,8 +50,8 @@ importers:
         specifier: ^6.4.3
         version: 6.4.3(picomatch@4.0.2)
       foxts:
-        specifier: ^2.0.1
-        version: 2.0.1
+        specifier: ^3.0.0
+        version: 3.0.0
       hash-wasm:
         specifier: ^4.12.0
         version: 4.12.0
@@ -1072,8 +1072,8 @@ packages:
   foxts@1.7.0:
     resolution: {integrity: sha512-mWyH/Fmh7TrUSuLgQpm2y3EieseR/v1g1Hp2cG5g5XBpQjuXLzhxMMiIND6egrDu0xkh28tYd4fp3dxam2/VAA==}
 
-  foxts@2.0.1:
-    resolution: {integrity: sha512-p032Uy9DFQEyWa0CjtK+KBlwujoRVzUUO9Z0OUAWLsK01pGQ2oqGX8XipzaVyR2i5yV4wAsQrjLoe7BWEhxH6A==}
+  foxts@3.0.0:
+    resolution: {integrity: sha512-h87E4IwITlcqmANBZdsywfINSKrx3pYo3KjXGI1dylZ1o7/UV4gh2PTNIo5xIB3Tn5M3iIGLiKsq+Q+zdktP7g==}
 
   fs-constants@1.0.0:
     resolution: {integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==}
@@ -2696,7 +2696,7 @@ snapshots:
     dependencies:
       uncrypto: 0.1.3
 
-  foxts@2.0.1: {}
+  foxts@3.0.0: {}
 
   fs-constants@1.0.0: {}