fpscanner 0.9.4 → 0.9.5-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/README.md +42 -15
  2. package/dist/detections/hasBotUserAgent.d.ts +3 -0
  3. package/dist/detections/hasBotUserAgent.d.ts.map +1 -0
  4. package/dist/detections/hasGPUMismatch.d.ts +3 -0
  5. package/dist/detections/hasGPUMismatch.d.ts.map +1 -0
  6. package/dist/detections/hasHeadlessChromeScreenResolution.d.ts.map +1 -1
  7. package/dist/detections/hasInconsistentEtsl.d.ts +3 -0
  8. package/dist/detections/hasInconsistentEtsl.d.ts.map +1 -0
  9. package/dist/detections/hasMismatchLanguages.d.ts +3 -0
  10. package/dist/detections/hasMismatchLanguages.d.ts.map +1 -0
  11. package/dist/detections/hasPlatformMismatch.d.ts +3 -0
  12. package/dist/detections/hasPlatformMismatch.d.ts.map +1 -0
  13. package/dist/fpScanner.cjs.js +2 -2
  14. package/dist/fpScanner.es.js +323 -223
  15. package/dist/index.d.ts +4 -4
  16. package/dist/index.d.ts.map +1 -1
  17. package/dist/signals/browserFeatures.d.ts +18 -0
  18. package/dist/signals/browserFeatures.d.ts.map +1 -1
  19. package/dist/signals/iframe.d.ts.map +1 -1
  20. package/dist/signals/worker.d.ts.map +1 -1
  21. package/dist/types.d.ts +23 -0
  22. package/dist/types.d.ts.map +1 -1
  23. package/package.json +6 -4
  24. package/scripts/safe-publish.js +111 -0
  25. package/src/detections/hasBotUserAgent.ts +11 -0
  26. package/src/detections/hasGPUMismatch.ts +25 -0
  27. package/src/detections/hasHeadlessChromeScreenResolution.ts +0 -3
  28. package/src/detections/hasImpossibleDeviceMemory.ts +1 -1
  29. package/src/detections/hasInconsistentEtsl.ts +21 -0
  30. package/src/detections/hasMismatchLanguages.ts +13 -0
  31. package/src/detections/hasPlatformMismatch.ts +46 -0
  32. package/src/index.ts +48 -5
  33. package/src/signals/browserFeatures.ts +37 -11
  34. package/src/signals/iframe.ts +9 -1
  35. package/src/signals/worker.ts +31 -8
  36. package/src/types.ts +23 -0
@@ -1,18 +1,18 @@
1
- function te() {
1
+ function ne() {
2
2
  return navigator.webdriver;
3
3
  }
4
- function re() {
4
+ function ie() {
5
5
  return navigator.userAgent;
6
6
  }
7
- function ne() {
7
+ function ae() {
8
8
  return navigator.platform;
9
9
  }
10
- const l = "ERROR", r = "INIT", s = "NA", p = "SKIPPED", g = "high", ie = "low", ae = "medium";
11
- function d(t) {
10
+ const l = "ERROR", r = "INIT", s = "NA", f = "SKIPPED", d = "high", b = "low", oe = "medium";
11
+ function p(t) {
12
12
  let e = 0;
13
- for (let n = 0, a = t.length; n < a; n++) {
14
- let i = t.charCodeAt(n);
15
- e = (e << 5) - e + i, e |= 0;
13
+ for (let n = 0, i = t.length; n < i; n++) {
14
+ let a = t.charCodeAt(n);
15
+ e = (e << 5) - e + a, e |= 0;
16
16
  }
17
17
  return e.toString(16).padStart(8, "0");
18
18
  }
@@ -20,10 +20,10 @@ function h(t, e) {
20
20
  for (const n in t)
21
21
  t[n] = e;
22
22
  }
23
- function oe() {
23
+ function se() {
24
24
  return navigator.buildID === "20181001000000";
25
25
  }
26
- function se() {
26
+ function ce() {
27
27
  try {
28
28
  let t = !1;
29
29
  const e = Error.prepareStackTrace;
@@ -36,12 +36,12 @@ function se() {
36
36
  return l;
37
37
  }
38
38
  }
39
- function ce() {
39
+ function le() {
40
40
  const t = {
41
41
  vendor: r,
42
42
  renderer: r
43
43
  };
44
- if (oe())
44
+ if (se())
45
45
  return h(t, s), t;
46
46
  try {
47
47
  var e = document.createElement("canvas"), n = e.getContext("webgl") || e.getContext("experimental-webgl");
@@ -51,35 +51,35 @@ function ce() {
51
51
  }
52
52
  return t;
53
53
  }
54
- function le() {
54
+ function ue() {
55
55
  return "__pwInitScripts" in window || "__playwright__binding__" in window;
56
56
  }
57
- function ue() {
57
+ function de() {
58
58
  return navigator.hardwareConcurrency || s;
59
59
  }
60
- function de() {
60
+ function he() {
61
61
  const t = [], e = 0.123456789;
62
- return ["E", "LN10", "LN2", "LOG10E", "LOG2E", "PI", "SQRT1_2", "SQRT2"].forEach(function(i) {
62
+ return ["E", "LN10", "LN2", "LOG10E", "LOG2E", "PI", "SQRT1_2", "SQRT2"].forEach(function(a) {
63
63
  try {
64
- t.push(Math[i]);
64
+ t.push(Math[a]);
65
65
  } catch {
66
66
  t.push(-1);
67
67
  }
68
- }), ["tan", "sin", "exp", "atan", "acosh", "asinh", "atanh", "expm1", "log1p", "sinh"].forEach(function(i) {
68
+ }), ["tan", "sin", "exp", "atan", "acosh", "asinh", "atanh", "expm1", "log1p", "sinh"].forEach(function(a) {
69
69
  try {
70
- t.push(Math[i](e));
70
+ t.push(Math[a](e));
71
71
  } catch {
72
72
  t.push(-1);
73
73
  }
74
- }), d(t.map(String).join(","));
74
+ }), p(t.map(String).join(","));
75
75
  }
76
- function he() {
76
+ function ge() {
77
77
  return navigator.deviceMemory || s;
78
78
  }
79
- function ge() {
79
+ function me() {
80
80
  return eval.toString().length;
81
81
  }
82
- function me() {
82
+ function pe() {
83
83
  const t = {
84
84
  timezone: r,
85
85
  localeLanguage: r
@@ -95,7 +95,7 @@ function me() {
95
95
  }
96
96
  return t;
97
97
  }
98
- function pe() {
98
+ function fe() {
99
99
  return {
100
100
  width: window.screen.width,
101
101
  height: window.screen.height,
@@ -108,13 +108,13 @@ function pe() {
108
108
  hasMultipleDisplays: typeof screen.isExtended < "u" ? screen.isExtended : s
109
109
  };
110
110
  }
111
- function fe() {
111
+ function ve() {
112
112
  return {
113
113
  languages: navigator.languages,
114
114
  language: navigator.language
115
115
  };
116
116
  }
117
- async function ve() {
117
+ async function we() {
118
118
  const t = {
119
119
  vendor: r,
120
120
  architecture: r,
@@ -166,7 +166,7 @@ function ye() {
166
166
  }
167
167
  return e = e || !!document.__webdriver_script_fn || !!window.domAutomation || !!window.domAutomationController, e;
168
168
  }
169
- function we() {
169
+ function be() {
170
170
  try {
171
171
  const t = "webdriver", e = window.navigator;
172
172
  if (!e[t] && !e.hasOwnProperty(t)) {
@@ -179,7 +179,7 @@ function we() {
179
179
  return !1;
180
180
  }
181
181
  }
182
- async function be() {
182
+ async function Se() {
183
183
  const t = window.navigator, e = {
184
184
  architecture: r,
185
185
  bitness: r,
@@ -210,22 +210,22 @@ async function be() {
210
210
  h(e, s);
211
211
  return e;
212
212
  }
213
- function Se() {
213
+ function Ce() {
214
214
  if (!navigator.plugins) return !1;
215
215
  const t = typeof navigator.plugins.toString == "function" ? navigator.plugins.toString() : navigator.plugins.constructor && typeof navigator.plugins.constructor.toString == "function" ? navigator.plugins.constructor.toString() : typeof navigator.plugins;
216
216
  return t === "[object PluginArray]" || t === "[object MSPluginsCollection]" || t === "[object HTMLPluginsCollection]";
217
217
  }
218
- function Ce() {
218
+ function Ae() {
219
219
  if (!navigator.plugins) return s;
220
220
  const t = [];
221
221
  for (let e = 0; e < navigator.plugins.length; e++)
222
222
  t.push(navigator.plugins[e].name);
223
- return d(t.join(","));
223
+ return p(t.join(","));
224
224
  }
225
- function We() {
225
+ function Pe() {
226
226
  return navigator.plugins ? navigator.plugins.length : s;
227
227
  }
228
- function ke() {
228
+ function Ee() {
229
229
  if (!navigator.plugins) return s;
230
230
  try {
231
231
  return navigator.plugins[0] === navigator.plugins[0][0].enabledPlugin;
@@ -233,7 +233,7 @@ function ke() {
233
233
  return l;
234
234
  }
235
235
  }
236
- function Ee() {
236
+ function We() {
237
237
  if (!navigator.plugins) return s;
238
238
  try {
239
239
  return navigator.plugins.item(4294967296) !== navigator.plugins[0];
@@ -241,7 +241,7 @@ function Ee() {
241
241
  return l;
242
242
  }
243
243
  }
244
- function Ae() {
244
+ function Me() {
245
245
  const t = {
246
246
  isValidPluginArray: r,
247
247
  pluginCount: r,
@@ -250,7 +250,7 @@ function Ae() {
250
250
  pluginOverflow: r
251
251
  };
252
252
  try {
253
- t.isValidPluginArray = Se(), t.pluginCount = We(), t.pluginNamesHash = Ce(), t.pluginConsistency1 = ke(), t.pluginOverflow = Ee();
253
+ t.isValidPluginArray = Ce(), t.pluginCount = Pe(), t.pluginNamesHash = Ae(), t.pluginConsistency1 = Ee(), t.pluginOverflow = We();
254
254
  } catch {
255
255
  h(t, l);
256
256
  }
@@ -264,11 +264,11 @@ async function xe() {
264
264
  videoinput: 0
265
265
  };
266
266
  if (navigator.mediaDevices && navigator.mediaDevices.enumerateDevices) {
267
- const i = await navigator.mediaDevices.enumerateDevices();
268
- if (typeof i < "u") {
269
- for (var n = 0; n < i.length; n++) {
270
- var a = i[n].kind;
271
- e[a] = e[a] + 1;
267
+ const a = await navigator.mediaDevices.enumerateDevices();
268
+ if (typeof a < "u") {
269
+ for (var n = 0; n < a.length; n++) {
270
+ var i = a[n].kind;
271
+ e[i] = e[i] + 1;
272
272
  }
273
273
  return t({
274
274
  speakers: e.audiooutput,
@@ -281,7 +281,7 @@ async function xe() {
281
281
  return h(e, s), t(e);
282
282
  });
283
283
  }
284
- function Pe() {
284
+ function ke() {
285
285
  const t = {
286
286
  webdriver: r,
287
287
  userAgent: r,
@@ -290,14 +290,19 @@ function Pe() {
290
290
  cpuCount: r,
291
291
  language: r
292
292
  }, e = document.createElement("iframe");
293
+ let n = !1;
293
294
  try {
294
- e.style.display = "none", e.src = "about:blank", document.body.appendChild(e);
295
- const n = e.contentWindow?.navigator;
296
- t.webdriver = n.webdriver ?? !1, t.userAgent = n.userAgent ?? s, t.platform = n.platform ?? s, t.memory = n.deviceMemory ?? s, t.cpuCount = n.hardwareConcurrency ?? s, t.language = n.language ?? s;
295
+ e.style.display = "none", e.src = "about:blank", document.body.appendChild(e), n = !0;
296
+ const i = e.contentWindow?.navigator;
297
+ t.webdriver = i.webdriver ?? !1, t.userAgent = i.userAgent ?? s, t.platform = i.platform ?? s, t.memory = i.deviceMemory ?? s, t.cpuCount = i.hardwareConcurrency ?? s, t.language = i.language ?? s;
297
298
  } catch {
298
299
  h(t, l);
299
300
  } finally {
300
- document.body.removeChild(e);
301
+ if (n)
302
+ try {
303
+ document.body.removeChild(e);
304
+ } catch {
305
+ }
301
306
  }
302
307
  return t;
303
308
  }
@@ -312,8 +317,12 @@ async function De() {
312
317
  memory: r,
313
318
  cpuCount: r
314
319
  };
320
+ let n = null, i = null, a = null;
321
+ const g = () => {
322
+ a && clearTimeout(a), n && n.terminate(), i && URL.revokeObjectURL(i);
323
+ };
315
324
  try {
316
- const n = `try {
325
+ const m = `try {
317
326
  var fingerprintWorker = {};
318
327
 
319
328
  fingerprintWorker.userAgent = navigator.userAgent;
@@ -343,20 +352,26 @@ async function De() {
343
352
  self.postMessage(fingerprintWorker);
344
353
  } catch (e) {
345
354
  self.postMessage(fingerprintWorker);
346
- }`, a = new Blob([n], { type: "application/javascript" }), i = URL.createObjectURL(a), m = new Worker(i);
347
- m.onmessage = function(u) {
355
+ }`, w = new Blob([m], { type: "application/javascript" });
356
+ i = URL.createObjectURL(w), n = new Worker(i), a = window.setTimeout(() => {
357
+ g(), h(e, l), t(e);
358
+ }, 2e3), n.onmessage = function(o) {
348
359
  try {
349
- return e.vendor = u.data.vendor, e.renderer = u.data.renderer, e.userAgent = u.data.userAgent, e.language = u.data.language, e.platform = u.data.platform, e.memory = u.data.memory, e.cpuCount = u.data.cpuCount, t(e);
360
+ e.vendor = o.data.vendor, e.renderer = o.data.renderer, e.userAgent = o.data.userAgent, e.language = o.data.language, e.platform = o.data.platform, e.memory = o.data.memory, e.cpuCount = o.data.cpuCount;
350
361
  } catch {
351
- return h(e, l), t(e);
362
+ h(e, l);
363
+ } finally {
364
+ g(), t(e);
352
365
  }
366
+ }, n.onerror = function() {
367
+ g(), h(e, l), t(e);
353
368
  };
354
369
  } catch {
355
- return h(e, l), t(e);
370
+ g(), h(e, l), t(e);
356
371
  }
357
372
  });
358
373
  }
359
- function Me() {
374
+ function _e() {
360
375
  const t = {
361
376
  toSourceError: r,
362
377
  hasToSource: !1
@@ -377,7 +392,7 @@ function Me() {
377
392
  }
378
393
  return t;
379
394
  }
380
- const w = [
395
+ const S = [
381
396
  'audio/mp4; codecs="mp4a.40.2"',
382
397
  "audio/mpeg;",
383
398
  'audio/webm; codecs="vorbis"',
@@ -386,7 +401,7 @@ const w = [
386
401
  'audio/ogg; codecs="speex"',
387
402
  'audio/ogg; codecs="flac"',
388
403
  'audio/3gpp; codecs="samr"'
389
- ], b = [
404
+ ], C = [
390
405
  'video/mp4; codecs="avc1.42E01E, mp4a.40.2"',
391
406
  'video/mp4; codecs="avc1.42E01E"',
392
407
  'video/mp4; codecs="avc1.58A01E"',
@@ -400,50 +415,50 @@ const w = [
400
415
  'video/3gpp; codecs="mp4v.20.8"',
401
416
  'video/x-matroska; codecs="theora"'
402
417
  ];
403
- function S(t, e) {
418
+ function A(t, e) {
404
419
  const n = {};
405
420
  try {
406
- const a = document.createElement(e);
407
- for (const i of t)
421
+ const i = document.createElement(e);
422
+ for (const a of t)
408
423
  try {
409
- n[i] = a.canPlayType(i) || null;
424
+ n[a] = i.canPlayType(a) || null;
410
425
  } catch {
411
- n[i] = null;
426
+ n[a] = null;
412
427
  }
413
428
  } catch {
414
- for (const a of t)
415
- n[a] = null;
429
+ for (const i of t)
430
+ n[i] = null;
416
431
  }
417
432
  return n;
418
433
  }
419
- function C(t) {
434
+ function P(t) {
420
435
  const e = {}, n = window.MediaSource;
421
436
  if (!n || typeof n.isTypeSupported != "function") {
422
- for (const a of t)
423
- e[a] = null;
437
+ for (const i of t)
438
+ e[i] = null;
424
439
  return e;
425
440
  }
426
- for (const a of t)
441
+ for (const i of t)
427
442
  try {
428
- e[a] = n.isTypeSupported(a);
443
+ e[i] = n.isTypeSupported(i);
429
444
  } catch {
430
- e[a] = null;
445
+ e[i] = null;
431
446
  }
432
447
  return e;
433
448
  }
434
- function W(t) {
449
+ function E(t) {
435
450
  try {
436
451
  const e = window.RTCRtpReceiver;
437
452
  if (e && typeof e.getCapabilities == "function") {
438
453
  const n = e.getCapabilities(t);
439
- return d(JSON.stringify(n));
454
+ return p(JSON.stringify(n));
440
455
  }
441
456
  return s;
442
457
  } catch {
443
458
  return l;
444
459
  }
445
460
  }
446
- function _e() {
461
+ function Re() {
447
462
  const t = {
448
463
  audioCanPlayTypeHash: s,
449
464
  videoCanPlayTypeHash: s,
@@ -455,21 +470,21 @@ function _e() {
455
470
  };
456
471
  try {
457
472
  t.hasMediaSource = !!window.MediaSource;
458
- const e = S(w, "audio"), n = S(b, "video");
459
- t.audioCanPlayTypeHash = d(JSON.stringify(e)), t.videoCanPlayTypeHash = d(JSON.stringify(n));
460
- const a = C(w), i = C(b);
461
- t.audioMediaSourceHash = d(JSON.stringify(a)), t.videoMediaSourceHash = d(JSON.stringify(i)), t.rtcAudioCapabilitiesHash = W("audio"), t.rtcVideoCapabilitiesHash = W("video");
473
+ const e = A(S, "audio"), n = A(C, "video");
474
+ t.audioCanPlayTypeHash = p(JSON.stringify(e)), t.videoCanPlayTypeHash = p(JSON.stringify(n));
475
+ const i = P(S), a = P(C);
476
+ t.audioMediaSourceHash = p(JSON.stringify(i)), t.videoMediaSourceHash = p(JSON.stringify(a)), t.rtcAudioCapabilitiesHash = E("audio"), t.rtcVideoCapabilitiesHash = E("video");
462
477
  } catch {
463
478
  h(t, l);
464
479
  }
465
480
  return t;
466
481
  }
467
- async function Re() {
482
+ async function Ie() {
468
483
  return new Promise((t) => {
469
484
  try {
470
485
  const e = new Image(), n = document.createElement("canvas").getContext("2d");
471
486
  e.onload = () => {
472
- n.drawImage(e, 0, 0), t(n.getImageData(0, 0, 1, 1).data.filter((a) => a === 0).length != 4);
487
+ n.drawImage(e, 0, 0), t(n.getImageData(0, 0, 1, 1).data.filter((i) => i === 0).length != 4);
473
488
  }, e.onerror = () => {
474
489
  t(l);
475
490
  }, e.src = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";
@@ -478,77 +493,102 @@ async function Re() {
478
493
  }
479
494
  });
480
495
  }
481
- function Ie() {
496
+ function Te() {
482
497
  var t = document.createElement("canvas");
483
498
  t.width = 400, t.height = 200, t.style.display = "inline";
484
499
  var e = t.getContext("2d");
485
500
  try {
486
- return e.rect(0, 0, 10, 10), e.rect(2, 2, 6, 6), e.textBaseline = "alphabetic", e.fillStyle = "#f60", e.fillRect(125, 1, 62, 20), e.fillStyle = "#069", e.font = "11pt no-real-font-123", e.fillText("Cwm fjordbank glyphs vext quiz, 😃", 2, 15), e.fillStyle = "rgba(102, 204, 0, 0.2)", e.font = "18pt Arial", e.fillText("Cwm fjordbank glyphs vext quiz, 😃", 4, 45), e.globalCompositeOperation = "multiply", e.fillStyle = "rgb(255,0,255)", e.beginPath(), e.arc(50, 50, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(0,255,255)", e.beginPath(), e.arc(100, 50, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(255,255,0)", e.beginPath(), e.arc(75, 100, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(255,0,255)", e.arc(75, 75, 75, 0, 2 * Math.PI, !0), e.arc(75, 75, 25, 0, 2 * Math.PI, !0), e.fill("evenodd"), d(t.toDataURL());
501
+ return e.rect(0, 0, 10, 10), e.rect(2, 2, 6, 6), e.textBaseline = "alphabetic", e.fillStyle = "#f60", e.fillRect(125, 1, 62, 20), e.fillStyle = "#069", e.font = "11pt no-real-font-123", e.fillText("Cwm fjordbank glyphs vext quiz, 😃", 2, 15), e.fillStyle = "rgba(102, 204, 0, 0.2)", e.font = "18pt Arial", e.fillText("Cwm fjordbank glyphs vext quiz, 😃", 4, 45), e.globalCompositeOperation = "multiply", e.fillStyle = "rgb(255,0,255)", e.beginPath(), e.arc(50, 50, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(0,255,255)", e.beginPath(), e.arc(100, 50, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(255,255,0)", e.beginPath(), e.arc(75, 100, 50, 0, 2 * Math.PI, !0), e.closePath(), e.fill(), e.fillStyle = "rgb(255,0,255)", e.arc(75, 75, 75, 0, 2 * Math.PI, !0), e.arc(75, 75, 25, 0, 2 * Math.PI, !0), e.fill("evenodd"), p(t.toDataURL());
487
502
  } catch {
488
503
  return l;
489
504
  }
490
505
  }
491
- async function Te() {
506
+ async function Le() {
492
507
  const t = {
493
508
  hasModifiedCanvas: r,
494
509
  canvasFingerprint: r
495
510
  };
496
- return t.hasModifiedCanvas = await Re(), t.canvasFingerprint = Ie(), t;
511
+ return t.hasModifiedCanvas = await Ie(), t.canvasFingerprint = Te(), t;
497
512
  }
498
- function He() {
513
+ function Oe() {
499
514
  const t = ["deviceMemory", "hardwareConcurrency", "language", "languages", "platform"], e = [];
500
515
  for (const n of t) {
501
- const a = Object.getOwnPropertyDescriptor(Object.getPrototypeOf(navigator), n);
502
- a && a.value ? e.push("1") : e.push("0");
516
+ const i = Object.getOwnPropertyDescriptor(Object.getPrototypeOf(navigator), n);
517
+ i && i.value ? e.push("1") : e.push("0");
503
518
  }
504
519
  return e.join("");
505
520
  }
506
- function Oe() {
521
+ function He() {
507
522
  return Math.random().toString(36).substring(2, 15);
508
523
  }
509
- function Le() {
524
+ function Ue() {
510
525
  return (/* @__PURE__ */ new Date()).getTime();
511
526
  }
512
527
  function Ve() {
513
528
  return window.location.href;
514
529
  }
515
- function k(t, e) {
530
+ function W(t, e) {
516
531
  const n = t.signals;
517
532
  return e === "iframe" ? n.contexts.iframe.webdriver !== n.automation.webdriver || n.contexts.iframe.userAgent !== n.browser.userAgent || n.contexts.iframe.platform !== n.device.platform || n.contexts.iframe.memory !== n.device.memory || n.contexts.iframe.cpuCount !== n.device.cpuCount : n.contexts.webWorker.webdriver !== n.automation.webdriver || n.contexts.webWorker.userAgent !== n.browser.userAgent || n.contexts.webWorker.platform !== n.device.platform || n.contexts.webWorker.memory !== n.device.memory || n.contexts.webWorker.cpuCount !== n.device.cpuCount;
518
533
  }
519
- function je() {
534
+ function Fe() {
520
535
  const t = {
521
536
  bitmask: r,
522
537
  extensions: []
523
- }, e = document.body.hasAttribute("data-gr-ext-installed"), n = typeof window.ethereum < "u", a = document.getElementById("coupon-birds-drop-div") !== null, i = document.querySelector("deepl-input-controller") !== null, m = document.getElementById("monica-content-root") !== null, u = document.querySelector("chatgpt-sidebar") !== null, v = typeof window.__REQUESTLY__ < "u", o = Array.from(document.querySelectorAll("*")).filter((f) => f.tagName.toLowerCase().startsWith("veepn-")).length > 0;
538
+ }, e = document.body.hasAttribute("data-gr-ext-installed"), n = typeof window.ethereum < "u", i = document.getElementById("coupon-birds-drop-div") !== null, a = document.querySelector("deepl-input-controller") !== null, g = document.getElementById("monica-content-root") !== null, m = document.querySelector("chatgpt-sidebar") !== null, w = typeof window.__REQUESTLY__ < "u", o = Array.from(document.querySelectorAll("*")).filter((v) => v.tagName.toLowerCase().startsWith("veepn-")).length > 0;
524
539
  return t.bitmask = [
525
540
  e ? "1" : "0",
526
541
  n ? "1" : "0",
527
- a ? "1" : "0",
528
542
  i ? "1" : "0",
543
+ a ? "1" : "0",
544
+ g ? "1" : "0",
529
545
  m ? "1" : "0",
530
- u ? "1" : "0",
531
- v ? "1" : "0",
546
+ w ? "1" : "0",
532
547
  o ? "1" : "0"
533
- ].join(""), e && t.extensions.push("grammarly"), n && t.extensions.push("metamask"), a && t.extensions.push("coupon-birds"), i && t.extensions.push("deepl"), m && t.extensions.push("monica-ai"), u && t.extensions.push("sider-ai"), v && t.extensions.push("requestly"), o && t.extensions.push("veepn"), t;
548
+ ].join(""), e && t.extensions.push("grammarly"), n && t.extensions.push("metamask"), i && t.extensions.push("coupon-birds"), a && t.extensions.push("deepl"), g && t.extensions.push("monica-ai"), m && t.extensions.push("sider-ai"), w && t.extensions.push("requestly"), o && t.extensions.push("veepn"), t;
549
+ }
550
+ function c(t) {
551
+ try {
552
+ return t();
553
+ } catch {
554
+ return !1;
555
+ }
534
556
  }
535
- function Ne() {
557
+ function Ge() {
536
558
  const t = {
537
559
  bitmask: r,
538
- chrome: "chrome" in window,
539
- brave: "brave" in navigator,
540
- applePaySupport: "ApplePaySetup" in window,
541
- opera: typeof window.opr < "u" || typeof window.onoperadetachedviewchange == "object",
542
- serial: window.navigator.serial !== void 0,
543
- attachShadow: !!Element.prototype.attachShadow,
544
- caches: !!window.caches,
545
- webAssembly: !!window.WebAssembly && !!window.WebAssembly.instantiate,
546
- buffer: "Buffer" in window,
547
- showModalDialog: "showModalDialog" in window
560
+ chrome: c(() => "chrome" in window),
561
+ brave: c(() => "brave" in navigator),
562
+ applePaySupport: c(() => "ApplePaySetup" in window),
563
+ opera: c(() => typeof window.opr < "u" || typeof window.onoperadetachedviewchange == "object"),
564
+ serial: c(() => window.navigator.serial !== void 0),
565
+ attachShadow: c(() => !!Element.prototype.attachShadow),
566
+ caches: c(() => !!window.caches),
567
+ webAssembly: c(() => !!window.WebAssembly && !!window.WebAssembly.instantiate),
568
+ buffer: c(() => "Buffer" in window),
569
+ showModalDialog: c(() => "showModalDialog" in window),
570
+ safari: c(() => "safari" in window),
571
+ webkitPrefixedFunction: c(() => "webkitCancelAnimationFrame" in window),
572
+ mozPrefixedFunction: c(() => "mozGetUserMedia" in navigator),
573
+ usb: c(() => typeof window.USB == "function"),
574
+ browserCapture: c(() => typeof window.BrowserCaptureMediaStreamTrack == "function"),
575
+ paymentRequestUpdateEvent: c(() => typeof window.PaymentRequestUpdateEvent == "function"),
576
+ pressureObserver: c(() => typeof window.PressureObserver == "function"),
577
+ audioSession: c(() => "audioSession" in navigator),
578
+ selectAudioOutput: c(() => typeof navigator < "u" && typeof navigator.mediaDevices < "u" && typeof navigator.mediaDevices.selectAudioOutput == "function"),
579
+ barcodeDetector: c(() => "BarcodeDetector" in window),
580
+ battery: c(() => "getBattery" in navigator),
581
+ devicePosture: c(() => "DevicePosture" in window),
582
+ documentPictureInPicture: c(() => "documentPictureInPicture" in window),
583
+ eyeDropper: c(() => "EyeDropper" in window),
584
+ editContext: c(() => "EditContext" in window),
585
+ fencedFrame: c(() => "FencedFrameConfig" in window),
586
+ sanitizer: c(() => "Sanitizer" in window),
587
+ otpCredential: c(() => "OTPCredential" in window)
548
588
  }, e = Object.keys(t).filter((n) => n !== "bitmask").map((n) => t[n] ? "1" : "0").join("");
549
589
  return t.bitmask = e, t;
550
590
  }
551
- function Ge() {
591
+ function Be() {
552
592
  const t = {
553
593
  prefersColorScheme: r,
554
594
  prefersReducedMotion: r,
@@ -571,65 +611,87 @@ function Ge() {
571
611
  }
572
612
  return t;
573
613
  }
574
- function Fe(t) {
614
+ function je(t) {
575
615
  const e = t.signals.device.screenResolution;
576
- return typeof e.width != "number" || typeof e.height != "number" ? !1 : e.width === 600 && e.height === 800 || e.availableWidth === 600 && e.availableHeight === 800 || e.innerWidth === 600 && e.innerHeight === 800;
616
+ return e.width === 600 && e.height === 800 || e.availableWidth === 600 && e.availableHeight === 800 || e.innerWidth === 600 && e.innerHeight === 800;
577
617
  }
578
- function Be(t) {
618
+ function Ne(t) {
579
619
  return t.signals.automation.webdriver === !0;
580
620
  }
581
621
  function ze(t) {
582
622
  return !!t.signals.automation.selenium;
583
623
  }
584
- function Ue(t) {
624
+ function $e(t) {
585
625
  return t.signals.automation.cdp === !0;
586
626
  }
587
- function $e(t) {
627
+ function Qe(t) {
588
628
  return t.signals.automation.playwright === !0;
589
629
  }
590
- function Qe(t) {
591
- return typeof t.signals.device.memory != "number" ? !1 : t.signals.device.memory > 8 || t.signals.device.memory < 0.25;
630
+ function qe(t) {
631
+ return typeof t.signals.device.memory != "number" ? !1 : t.signals.device.memory > 32 || t.signals.device.memory < 0.25;
592
632
  }
593
633
  function Ke(t) {
594
634
  return typeof t.signals.device.cpuCount != "number" ? !1 : t.signals.device.cpuCount > 70;
595
635
  }
596
- function qe(t) {
636
+ function Je(t) {
597
637
  const e = t.signals.browser.userAgent;
598
638
  return t.signals.browser.features.chrome === !1 && typeof e == "string" && e.includes("Chrome");
599
639
  }
600
- function Je(t) {
601
- return t.signals.contexts.iframe.webdriver === !0;
602
- }
603
640
  function Ye(t) {
604
- return t.signals.contexts.webWorker.webdriver === !0;
641
+ return t.signals.contexts.iframe.webdriver === !0;
605
642
  }
606
643
  function Ze(t) {
607
- const e = t.signals.contexts.webWorker, n = t.signals.graphics.webGL;
608
- return e.vendor === l || e.renderer === l || n.vendor === s || n.renderer === s || e.vendor === p ? !1 : e.vendor !== n.vendor || e.renderer !== n.renderer;
644
+ return t.signals.contexts.webWorker.webdriver === !0;
609
645
  }
610
646
  function Xe(t) {
611
- return t.signals.contexts.webWorker.platform === s || t.signals.contexts.webWorker.platform === l || t.signals.contexts.webWorker.platform === p ? !1 : t.signals.device.platform !== t.signals.contexts.webWorker.platform;
647
+ const e = t.signals.contexts.webWorker, n = t.signals.graphics.webGL;
648
+ return e.vendor === l || e.renderer === l || n.vendor === s || n.renderer === s || e.vendor === f ? !1 : e.vendor !== n.vendor || e.renderer !== n.renderer;
612
649
  }
613
650
  function et(t) {
614
- return t.signals.contexts.iframe.platform === s || t.signals.contexts.iframe.platform === l ? !1 : t.signals.device.platform !== t.signals.contexts.iframe.platform;
651
+ return t.signals.contexts.webWorker.platform === s || t.signals.contexts.webWorker.platform === l || t.signals.contexts.webWorker.platform === f ? !1 : t.signals.device.platform !== t.signals.contexts.webWorker.platform;
615
652
  }
616
653
  function tt(t) {
617
- return t.signals.automation.webdriverWritable === !0;
654
+ return t.signals.contexts.iframe.platform === s || t.signals.contexts.iframe.platform === l ? !1 : t.signals.device.platform !== t.signals.contexts.iframe.platform;
618
655
  }
619
656
  function rt(t) {
620
- return t.signals.graphics.webGL.renderer.includes("SwiftShader");
657
+ return t.signals.automation.webdriverWritable === !0;
621
658
  }
622
659
  function nt(t) {
660
+ return t.signals.graphics.webGL.renderer.includes("SwiftShader");
661
+ }
662
+ function it(t) {
623
663
  return t.signals.locale.internationalization.timezone === "UTC";
624
664
  }
625
- async function it(t, e) {
626
- const n = new TextEncoder().encode(e), a = new TextEncoder().encode(t), i = new Uint8Array(a.length);
627
- for (let u = 0; u < a.length; u++)
628
- i[u] = a[u] ^ n[u % n.length];
629
- const m = String.fromCharCode(...i);
630
- return btoa(m);
665
+ function at(t) {
666
+ const e = t.signals.locale.languages.languages, n = t.signals.locale.languages.language;
667
+ return n && e && Array.isArray(e) && e.length > 0 ? e[0] !== n : !1;
668
+ }
669
+ function ot(t) {
670
+ return !!(t.signals.browser.features.chrome && t.signals.browser.etsl !== 33 || t.signals.browser.features.safari && t.signals.browser.etsl !== 37 || t.signals.browser.userAgent.includes("Firefox") && t.signals.browser.etsl !== 37);
631
671
  }
632
- class ot {
672
+ function st(t) {
673
+ return [
674
+ t.signals.browser.userAgent,
675
+ t.signals.contexts.iframe.userAgent,
676
+ t.signals.contexts.webWorker.userAgent
677
+ ].some((n) => /bot|headless/i.test(n.toLowerCase()));
678
+ }
679
+ function ct(t) {
680
+ const e = t.signals.graphics.webgpu, n = t.signals.graphics.webGL, i = t.signals.browser.userAgent;
681
+ return !!((n.vendor.includes("Apple") || n.renderer.includes("Apple")) && !i.includes("Mac") || e.vendor.includes("apple") && !i.includes("Mac") || e.vendor.includes("apple") && !n.renderer.includes("Apple"));
682
+ }
683
+ function lt(t) {
684
+ const e = t.signals.device.platform, n = t.signals.browser.userAgent, i = t.signals.browser.highEntropyValues.platform;
685
+ return !!(n.includes("Mac") && !e.includes("Mac") || n.includes("Windows") && !e.includes("Win") || n.includes("Linux") && !e.includes("Linux") || i !== l && i !== s && (i.includes("Mac") && !e.includes("Mac") || i.includes("Windows") && !e.includes("Win") || i.includes("Linux") && !e.includes("Linux") || i.includes("Android") && !e.includes("Android") || i.includes("iOS") && !e.includes("iOS")));
686
+ }
687
+ async function ut(t, e) {
688
+ const n = new TextEncoder().encode(e), i = new TextEncoder().encode(t), a = new Uint8Array(i.length);
689
+ for (let m = 0; m < i.length; m++)
690
+ a[m] = i[m] ^ n[m % n.length];
691
+ const g = String.fromCharCode(...a);
692
+ return btoa(g);
693
+ }
694
+ class ht {
633
695
  constructor() {
634
696
  this.fingerprint = {
635
697
  signals: {
@@ -689,7 +751,25 @@ class ot {
689
751
  caches: r,
690
752
  webAssembly: r,
691
753
  buffer: r,
692
- showModalDialog: r
754
+ showModalDialog: r,
755
+ safari: r,
756
+ webkitPrefixedFunction: r,
757
+ mozPrefixedFunction: r,
758
+ usb: r,
759
+ browserCapture: r,
760
+ paymentRequestUpdateEvent: r,
761
+ pressureObserver: r,
762
+ audioSession: r,
763
+ selectAudioOutput: r,
764
+ barcodeDetector: r,
765
+ battery: r,
766
+ devicePosture: r,
767
+ documentPictureInPicture: r,
768
+ eyeDropper: r,
769
+ editContext: r,
770
+ fencedFrame: r,
771
+ sanitizer: r,
772
+ otpCredential: r
693
773
  },
694
774
  plugins: {
695
775
  isValidPluginArray: r,
@@ -800,7 +880,12 @@ class ot {
800
880
  hasMismatchPlatformIframe: { detected: !1, severity: "high" },
801
881
  hasMismatchPlatformWorker: { detected: !1, severity: "high" },
802
882
  hasSwiftshaderRenderer: { detected: !1, severity: "low" },
803
- hasUTCTimezone: { detected: !1, severity: "medium" }
883
+ hasUTCTimezone: { detected: !1, severity: "medium" },
884
+ hasMismatchLanguages: { detected: !1, severity: "low" },
885
+ hasInconsistentEtsl: { detected: !1, severity: "high" },
886
+ hasBotUserAgent: { detected: !1, severity: "high" },
887
+ hasGPUMismatch: { detected: !1, severity: "high" },
888
+ hasPlatformMismatch: { detected: !1, severity: "high" }
804
889
  }
805
890
  };
806
891
  }
@@ -820,10 +905,11 @@ class ot {
820
905
  * Bitmasks are extensible - new boolean fields are appended without breaking existing positions.
821
906
  *
822
907
  * Sections:
823
- * - det: fastBotDetectionDetails bitmask (14 bits: headlessChromeScreenResolution, hasWebdriver,
908
+ * - det: fastBotDetectionDetails bitmask (21 bits: headlessChromeScreenResolution, hasWebdriver,
824
909
  * hasWebdriverWritable, hasSeleniumProperty, hasCDP, hasPlaywright, hasImpossibleDeviceMemory,
825
910
  * hasHighCPUCount, hasMissingChromeObject, hasWebdriverIframe, hasWebdriverWorker,
826
- * hasMismatchWebGLInWorker, hasMismatchPlatformIframe, hasMismatchPlatformWorker)
911
+ * hasMismatchWebGLInWorker, hasMismatchPlatformIframe, hasMismatchPlatformWorker,
912
+ * hasMismatchLanguages, hasInconsistentEtsl, hasBotUserAgent, hasGPUMismatch, hasPlatformMismatch)
827
913
  * - auto: automation bitmask (5 bits: webdriver, webdriverWritable, selenium, cdp, playwright) + hash
828
914
  * - dev: WIDTHxHEIGHT + cpu + mem + device bitmask + hash of all device signals
829
915
  * - brw: features.bitmask + extensions.bitmask + plugins bitmask (3 bits) + hash of browser signals
@@ -834,7 +920,7 @@ class ot {
834
920
  */
835
921
  generateFingerprintScannerId() {
836
922
  try {
837
- const e = this.fingerprint.signals, n = this.fingerprint.fastBotDetectionDetails, a = "FS1", m = [
923
+ const e = this.fingerprint.signals, n = this.fingerprint.fastBotDetectionDetails, i = "FS1", g = [
838
924
  n.headlessChromeScreenResolution.detected,
839
925
  n.hasWebdriver.detected,
840
926
  n.hasWebdriverWritable.detected,
@@ -850,21 +936,26 @@ class ot {
850
936
  n.hasMismatchPlatformIframe.detected,
851
937
  n.hasMismatchPlatformWorker.detected,
852
938
  n.hasSwiftshaderRenderer.detected,
853
- n.hasUTCTimezone.detected
939
+ n.hasUTCTimezone.detected,
940
+ n.hasMismatchLanguages.detected,
941
+ n.hasInconsistentEtsl.detected,
942
+ n.hasBotUserAgent.detected,
943
+ n.hasGPUMismatch.detected,
944
+ n.hasPlatformMismatch.detected
854
945
  // Add other detection rules output here
855
- ].map((c) => c ? "1" : "0").join(""), u = [
946
+ ].map((u) => u ? "1" : "0").join(""), m = [
856
947
  e.automation.webdriver === !0,
857
948
  e.automation.webdriverWritable === !0,
858
949
  e.automation.selenium === !0,
859
950
  e.automation.cdp === !0,
860
951
  e.automation.playwright === !0
861
- ].map((c) => c ? "1" : "0").join(""), v = d(String(e.automation.navigatorPropertyDescriptors)).slice(0, 4), o = `${u}h${v}`, f = typeof e.device.screenResolution.width == "number" ? e.device.screenResolution.width : 0, y = typeof e.device.screenResolution.height == "number" ? e.device.screenResolution.height : 0, E = typeof e.device.cpuCount == "number" ? String(e.device.cpuCount).padStart(2, "0") : "00", A = typeof e.device.memory == "number" ? String(Math.round(e.device.memory)).padStart(2, "0") : "00", x = [
952
+ ].map((u) => u ? "1" : "0").join(""), w = p(String(e.automation.navigatorPropertyDescriptors)).slice(0, 4), o = `${m}h${w}`, v = typeof e.device.screenResolution.width == "number" ? e.device.screenResolution.width : 0, y = typeof e.device.screenResolution.height == "number" ? e.device.screenResolution.height : 0, M = typeof e.device.cpuCount == "number" ? String(e.device.cpuCount).padStart(2, "0") : "00", x = typeof e.device.memory == "number" ? String(Math.round(e.device.memory)).padStart(2, "0") : "00", k = [
862
953
  e.device.screenResolution.hasMultipleDisplays === !0,
863
954
  e.device.mediaQueries.prefersReducedMotion === !0,
864
955
  e.device.mediaQueries.prefersReducedTransparency === !0,
865
956
  e.device.mediaQueries.hover === !0,
866
957
  e.device.mediaQueries.anyHover === !0
867
- ].map((c) => c ? "1" : "0").join(""), P = [
958
+ ].map((u) => u ? "1" : "0").join(""), D = [
868
959
  e.device.platform,
869
960
  e.device.screenResolution.pixelDepth,
870
961
  e.device.screenResolution.colorDepth,
@@ -876,12 +967,12 @@ class ot {
876
967
  e.device.mediaQueries.pointer,
877
968
  e.device.mediaQueries.anyPointer,
878
969
  e.device.mediaQueries.colorDepth
879
- ].map((c) => String(c)).join("|"), D = d(P).slice(0, 6), M = `${f}x${y}c${E}m${A}b${x}h${D}`, _ = typeof e.browser.features.bitmask == "string" ? e.browser.features.bitmask : "0000000000", R = typeof e.browser.extensions.bitmask == "string" ? e.browser.extensions.bitmask : "00000000", I = [
970
+ ].map((u) => String(u)).join("|"), _ = p(D).slice(0, 6), R = `${v}x${y}c${M}m${x}b${k}h${_}`, I = typeof e.browser.features.bitmask == "string" ? e.browser.features.bitmask : "0000000000", T = typeof e.browser.extensions.bitmask == "string" ? e.browser.extensions.bitmask : "00000000", L = [
880
971
  e.browser.plugins.isValidPluginArray === !0,
881
972
  e.browser.plugins.pluginConsistency1 === !0,
882
973
  e.browser.plugins.pluginOverflow === !0,
883
974
  e.browser.toSourceError.hasToSource === !0
884
- ].map((c) => c ? "1" : "0").join(""), T = [
975
+ ].map((u) => u ? "1" : "0").join(""), O = [
885
976
  e.browser.userAgent,
886
977
  e.browser.etsl,
887
978
  e.browser.maths,
@@ -894,9 +985,9 @@ class ot {
894
985
  e.browser.highEntropyValues.platformVersion,
895
986
  e.browser.highEntropyValues.uaFullVersion,
896
987
  e.browser.highEntropyValues.mobile
897
- ].map((c) => String(c)).join("|"), H = d(T).slice(0, 6), O = `f${_}e${R}p${I}h${H}`, L = [
988
+ ].map((u) => String(u)).join("|"), H = p(O).slice(0, 6), U = `f${I}e${T}p${L}h${H}`, V = [
898
989
  e.graphics.canvas.hasModifiedCanvas === !0
899
- ].map((c) => c ? "1" : "0").join(""), V = [
990
+ ].map((u) => u ? "1" : "0").join(""), F = [
900
991
  e.graphics.webGL.vendor,
901
992
  e.graphics.webGL.renderer,
902
993
  e.graphics.webgpu.vendor,
@@ -904,26 +995,26 @@ class ot {
904
995
  e.graphics.webgpu.device,
905
996
  e.graphics.webgpu.description,
906
997
  e.graphics.canvas.canvasFingerprint
907
- ].map((c) => String(c)).join("|"), j = d(V).slice(0, 6), N = `${L}h${j}`, G = [
998
+ ].map((u) => String(u)).join("|"), G = p(F).slice(0, 6), B = `${V}h${G}`, j = [
908
999
  e.codecs.hasMediaSource === !0
909
- ].map((c) => c ? "1" : "0").join(""), F = [
1000
+ ].map((u) => u ? "1" : "0").join(""), N = [
910
1001
  e.codecs.audioCanPlayTypeHash,
911
1002
  e.codecs.videoCanPlayTypeHash,
912
1003
  e.codecs.audioMediaSourceHash,
913
1004
  e.codecs.videoMediaSourceHash,
914
1005
  e.codecs.rtcAudioCapabilitiesHash,
915
1006
  e.codecs.rtcVideoCapabilitiesHash
916
- ].map((c) => String(c)).join("|"), B = d(F).slice(0, 6), z = `${G}h${B}`, U = typeof e.locale.languages.language == "string" ? e.locale.languages.language.slice(0, 2).toLowerCase() : "xx", $ = Array.isArray(e.locale.languages.languages) ? e.locale.languages.languages.length : 0, Q = (typeof e.locale.internationalization.timezone == "string" ? e.locale.internationalization.timezone : "unknown").replace(/[\/\s]/g, "-"), K = [
1007
+ ].map((u) => String(u)).join("|"), z = p(N).slice(0, 6), $ = `${j}h${z}`, Q = typeof e.locale.languages.language == "string" ? e.locale.languages.language.slice(0, 2).toLowerCase() : "xx", q = Array.isArray(e.locale.languages.languages) ? e.locale.languages.languages.length : 0, K = (typeof e.locale.internationalization.timezone == "string" ? e.locale.internationalization.timezone : "unknown").replace(/[\/\s]/g, "-"), J = [
917
1008
  e.locale.internationalization.timezone,
918
1009
  e.locale.internationalization.localeLanguage,
919
1010
  Array.isArray(e.locale.languages.languages) ? e.locale.languages.languages.join(",") : e.locale.languages.languages,
920
1011
  e.locale.languages.language
921
- ].map((c) => String(c)).join("|"), q = d(K).slice(0, 4), J = `${U}${$}t${Q}_h${q}`, Y = [
922
- k(this.fingerprint, "iframe"),
923
- k(this.fingerprint, "worker"),
1012
+ ].map((u) => String(u)).join("|"), Y = p(J).slice(0, 4), Z = `${Q}${q}t${K}_h${Y}`, X = [
1013
+ W(this.fingerprint, "iframe"),
1014
+ W(this.fingerprint, "worker"),
924
1015
  e.contexts.iframe.webdriver === !0,
925
1016
  e.contexts.webWorker.webdriver === !0
926
- ].map((c) => c ? "1" : "0").join(""), Z = [
1017
+ ].map((u) => u ? "1" : "0").join(""), ee = [
927
1018
  e.contexts.iframe.userAgent,
928
1019
  e.contexts.iframe.platform,
929
1020
  e.contexts.iframe.memory,
@@ -936,17 +1027,17 @@ class ot {
936
1027
  e.contexts.webWorker.language,
937
1028
  e.contexts.webWorker.vendor,
938
1029
  e.contexts.webWorker.renderer
939
- ].map((c) => String(c)).join("|"), X = d(Z).slice(0, 6), ee = `${Y}h${X}`;
1030
+ ].map((u) => String(u)).join("|"), te = p(ee).slice(0, 6), re = `${X}h${te}`;
940
1031
  return [
941
- a,
942
- m,
1032
+ i,
1033
+ g,
943
1034
  o,
944
- M,
945
- O,
946
- N,
947
- z,
948
- J,
949
- ee
1035
+ R,
1036
+ U,
1037
+ B,
1038
+ $,
1039
+ Z,
1040
+ re
950
1041
  ].join("_");
951
1042
  } catch (e) {
952
1043
  return console.error("Error generating fingerprint scanner id", e), l;
@@ -956,30 +1047,34 @@ class ot {
956
1047
  const n = "__DEFAULT_FPSCANNER_KEY__";
957
1048
  return n.length > 20 && n.indexOf("DEFAULT") > 0 && n.indexOf("FPSCANNER") > 0 && console.warn(
958
1049
  '[fpscanner] WARNING: Using default encryption key! Run "npx fpscanner build --key=your-secret-key" to inject your own key. See: https://github.com/antoinevastel/fpscanner#advanced-custom-builds'
959
- ), await it(JSON.stringify(e), n);
1050
+ ), await ut(JSON.stringify(e), n);
960
1051
  }
961
1052
  /**
962
1053
  * Detection rules with name and severity.
963
- * All rules are currently HIGH severity as they indicate bot-like behavior.
964
- */
1054
+ */
965
1055
  getDetectionRules() {
966
1056
  return [
967
- { name: "headlessChromeScreenResolution", severity: g, test: Fe },
968
- { name: "hasWebdriver", severity: g, test: Be },
969
- { name: "hasWebdriverWritable", severity: g, test: tt },
970
- { name: "hasSeleniumProperty", severity: g, test: ze },
971
- { name: "hasCDP", severity: g, test: Ue },
972
- { name: "hasPlaywright", severity: g, test: $e },
973
- { name: "hasImpossibleDeviceMemory", severity: g, test: Qe },
974
- { name: "hasHighCPUCount", severity: g, test: Ke },
975
- { name: "hasMissingChromeObject", severity: g, test: qe },
976
- { name: "hasWebdriverIframe", severity: g, test: Je },
977
- { name: "hasWebdriverWorker", severity: g, test: Ye },
978
- { name: "hasMismatchWebGLInWorker", severity: g, test: Ze },
979
- { name: "hasMismatchPlatformIframe", severity: g, test: et },
980
- { name: "hasMismatchPlatformWorker", severity: g, test: Xe },
981
- { name: "hasSwiftshaderRenderer", severity: ie, test: rt },
982
- { name: "hasUTCTimezone", severity: ae, test: nt }
1057
+ { name: "headlessChromeScreenResolution", severity: d, test: je },
1058
+ { name: "hasWebdriver", severity: d, test: Ne },
1059
+ { name: "hasWebdriverWritable", severity: d, test: rt },
1060
+ { name: "hasSeleniumProperty", severity: d, test: ze },
1061
+ { name: "hasCDP", severity: d, test: $e },
1062
+ { name: "hasPlaywright", severity: d, test: Qe },
1063
+ { name: "hasImpossibleDeviceMemory", severity: d, test: qe },
1064
+ { name: "hasHighCPUCount", severity: d, test: Ke },
1065
+ { name: "hasMissingChromeObject", severity: d, test: Je },
1066
+ { name: "hasWebdriverIframe", severity: d, test: Ye },
1067
+ { name: "hasWebdriverWorker", severity: d, test: Ze },
1068
+ { name: "hasMismatchWebGLInWorker", severity: d, test: Xe },
1069
+ { name: "hasMismatchPlatformIframe", severity: d, test: tt },
1070
+ { name: "hasMismatchPlatformWorker", severity: d, test: et },
1071
+ { name: "hasSwiftshaderRenderer", severity: b, test: nt },
1072
+ { name: "hasUTCTimezone", severity: oe, test: it },
1073
+ { name: "hasMismatchLanguages", severity: b, test: at },
1074
+ { name: "hasInconsistentEtsl", severity: d, test: ot },
1075
+ { name: "hasBotUserAgent", severity: d, test: st },
1076
+ { name: "hasGPUMismatch", severity: d, test: ct },
1077
+ { name: "hasPlatformMismatch", severity: d, test: lt }
983
1078
  ];
984
1079
  }
985
1080
  runDetectionRules() {
@@ -999,71 +1094,76 @@ class ot {
999
1094
  hasMismatchPlatformIframe: { detected: !1, severity: "high" },
1000
1095
  hasMismatchPlatformWorker: { detected: !1, severity: "high" },
1001
1096
  hasSwiftshaderRenderer: { detected: !1, severity: "low" },
1002
- hasUTCTimezone: { detected: !1, severity: "medium" }
1097
+ hasUTCTimezone: { detected: !1, severity: "medium" },
1098
+ hasMismatchLanguages: { detected: !1, severity: "low" },
1099
+ hasInconsistentEtsl: { detected: !1, severity: "high" },
1100
+ hasBotUserAgent: { detected: !1, severity: "high" },
1101
+ hasGPUMismatch: { detected: !1, severity: "high" },
1102
+ hasPlatformMismatch: { detected: !1, severity: "high" }
1003
1103
  };
1004
- for (const a of e)
1104
+ for (const i of e)
1005
1105
  try {
1006
- const i = a.test(this.fingerprint);
1007
- n[a.name] = { detected: i, severity: a.severity };
1106
+ const a = i.test(this.fingerprint);
1107
+ n[i.name] = { detected: a, severity: i.severity };
1008
1108
  } catch {
1009
- n[a.name] = { detected: !1, severity: a.severity };
1109
+ n[i.name] = { detected: !1, severity: i.severity };
1010
1110
  }
1011
1111
  return n;
1012
1112
  }
1013
1113
  async collectFingerprint(e = { encrypt: !0 }) {
1014
- const { encrypt: n = !0, skipWorker: a = !1 } = e, i = this.fingerprint.signals, m = {
1114
+ const { encrypt: n = !0, skipWorker: i = !1 } = e, a = this.fingerprint.signals, g = {
1015
1115
  // Automation signals
1016
- webdriver: this.collectSignal(te),
1017
- webdriverWritable: this.collectSignal(we),
1116
+ webdriver: this.collectSignal(ne),
1117
+ webdriverWritable: this.collectSignal(be),
1018
1118
  selenium: this.collectSignal(ye),
1019
- cdp: this.collectSignal(se),
1020
- playwright: this.collectSignal(le),
1021
- navigatorPropertyDescriptors: this.collectSignal(He),
1119
+ cdp: this.collectSignal(ce),
1120
+ playwright: this.collectSignal(ue),
1121
+ navigatorPropertyDescriptors: this.collectSignal(Oe),
1022
1122
  // Device signals
1023
- cpuCount: this.collectSignal(ue),
1024
- memory: this.collectSignal(he),
1025
- platform: this.collectSignal(ne),
1026
- screenResolution: this.collectSignal(pe),
1123
+ cpuCount: this.collectSignal(de),
1124
+ memory: this.collectSignal(ge),
1125
+ platform: this.collectSignal(ae),
1126
+ screenResolution: this.collectSignal(fe),
1027
1127
  multimediaDevices: this.collectSignal(xe),
1028
- mediaQueries: this.collectSignal(Ge),
1128
+ mediaQueries: this.collectSignal(Be),
1029
1129
  // Browser signals
1030
- userAgent: this.collectSignal(re),
1031
- browserFeatures: this.collectSignal(Ne),
1032
- plugins: this.collectSignal(Ae),
1033
- browserExtensions: this.collectSignal(je),
1034
- highEntropyValues: this.collectSignal(be),
1035
- etsl: this.collectSignal(ge),
1036
- maths: this.collectSignal(de),
1037
- toSourceError: this.collectSignal(Me),
1130
+ userAgent: this.collectSignal(ie),
1131
+ browserFeatures: this.collectSignal(Ge),
1132
+ plugins: this.collectSignal(Me),
1133
+ browserExtensions: this.collectSignal(Fe),
1134
+ highEntropyValues: this.collectSignal(Se),
1135
+ etsl: this.collectSignal(me),
1136
+ maths: this.collectSignal(he),
1137
+ toSourceError: this.collectSignal(_e),
1038
1138
  // Graphics signals
1039
- webGL: this.collectSignal(ce),
1040
- webgpu: this.collectSignal(ve),
1041
- canvas: this.collectSignal(Te),
1139
+ webGL: this.collectSignal(le),
1140
+ webgpu: this.collectSignal(we),
1141
+ canvas: this.collectSignal(Le),
1042
1142
  // Codecs
1043
- mediaCodecs: this.collectSignal(_e),
1143
+ mediaCodecs: this.collectSignal(Re),
1044
1144
  // Locale signals
1045
- internationalization: this.collectSignal(me),
1046
- languages: this.collectSignal(fe),
1145
+ internationalization: this.collectSignal(pe),
1146
+ languages: this.collectSignal(ve),
1047
1147
  // Context signals
1048
- iframe: this.collectSignal(Pe),
1049
- webWorker: a ? Promise.resolve({
1050
- webdriver: p,
1051
- userAgent: p,
1052
- platform: p,
1053
- memory: p,
1054
- cpuCount: p,
1055
- language: p,
1056
- vendor: p,
1057
- renderer: p
1148
+ iframe: this.collectSignal(ke),
1149
+ webWorker: i ? Promise.resolve({
1150
+ webdriver: f,
1151
+ userAgent: f,
1152
+ platform: f,
1153
+ memory: f,
1154
+ cpuCount: f,
1155
+ language: f,
1156
+ vendor: f,
1157
+ renderer: f
1058
1158
  }) : this.collectSignal(De),
1059
1159
  // Meta signals
1060
- nonce: this.collectSignal(Oe),
1061
- time: this.collectSignal(Le),
1160
+ nonce: this.collectSignal(He),
1161
+ time: this.collectSignal(Ue),
1062
1162
  url: this.collectSignal(Ve)
1063
- }, u = Object.keys(m), v = await Promise.all(Object.values(m)), o = Object.fromEntries(u.map((f, y) => [f, v[y]]));
1064
- return i.automation.webdriver = o.webdriver, i.automation.webdriverWritable = o.webdriverWritable, i.automation.selenium = o.selenium, i.automation.cdp = o.cdp, i.automation.playwright = o.playwright, i.automation.navigatorPropertyDescriptors = o.navigatorPropertyDescriptors, i.device.cpuCount = o.cpuCount, i.device.memory = o.memory, i.device.platform = o.platform, i.device.screenResolution = o.screenResolution, i.device.multimediaDevices = o.multimediaDevices, i.device.mediaQueries = o.mediaQueries, i.browser.userAgent = o.userAgent, i.browser.features = o.browserFeatures, i.browser.plugins = o.plugins, i.browser.extensions = o.browserExtensions, i.browser.highEntropyValues = o.highEntropyValues, i.browser.etsl = o.etsl, i.browser.maths = o.maths, i.browser.toSourceError = o.toSourceError, i.graphics.webGL = o.webGL, i.graphics.webgpu = o.webgpu, i.graphics.canvas = o.canvas, i.codecs = o.mediaCodecs, i.locale.internationalization = o.internationalization, i.locale.languages = o.languages, i.contexts.iframe = o.iframe, i.contexts.webWorker = o.webWorker, this.fingerprint.nonce = o.nonce, this.fingerprint.time = o.time, this.fingerprint.url = o.url, this.fingerprint.fastBotDetectionDetails = this.runDetectionRules(), this.fingerprint.fastBotDetection = Object.values(this.fingerprint.fastBotDetectionDetails).some((f) => f.detected), this.fingerprint.fsid = this.generateFingerprintScannerId(), n ? await this.encryptFingerprint(JSON.stringify(this.fingerprint)) : this.fingerprint;
1163
+ }, m = Object.keys(g), w = await Promise.all(Object.values(g)), o = Object.fromEntries(m.map((v, y) => [v, w[y]]));
1164
+ return a.automation.webdriver = o.webdriver, a.automation.webdriverWritable = o.webdriverWritable, a.automation.selenium = o.selenium, a.automation.cdp = o.cdp, a.automation.playwright = o.playwright, a.automation.navigatorPropertyDescriptors = o.navigatorPropertyDescriptors, a.device.cpuCount = o.cpuCount, a.device.memory = o.memory, a.device.platform = o.platform, a.device.screenResolution = o.screenResolution, a.device.multimediaDevices = o.multimediaDevices, a.device.mediaQueries = o.mediaQueries, a.browser.userAgent = o.userAgent, a.browser.features = o.browserFeatures, a.browser.plugins = o.plugins, a.browser.extensions = o.browserExtensions, a.browser.highEntropyValues = o.highEntropyValues, a.browser.etsl = o.etsl, a.browser.maths = o.maths, a.browser.toSourceError = o.toSourceError, a.graphics.webGL = o.webGL, a.graphics.webgpu = o.webgpu, a.graphics.canvas = o.canvas, a.codecs = o.mediaCodecs, a.locale.internationalization = o.internationalization, a.locale.languages = o.languages, a.contexts.iframe = o.iframe, a.contexts.webWorker = o.webWorker, this.fingerprint.nonce = o.nonce, this.fingerprint.time = o.time, this.fingerprint.url = o.url, this.fingerprint.fastBotDetectionDetails = this.runDetectionRules(), this.fingerprint.fastBotDetection = Object.values(this.fingerprint.fastBotDetectionDetails).some((v) => v.detected), this.fingerprint.fsid = this.generateFingerprintScannerId(), n ? await this.encryptFingerprint(JSON.stringify(this.fingerprint)) : this.fingerprint;
1065
1165
  }
1066
1166
  }
1067
1167
  export {
1068
- ot as default
1168
+ ht as default
1069
1169
  };