jumpy-lion 0.0.41 → 0.0.43
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.
- package/dist/browser-controller.d.ts.map +1 -1
- package/dist/browser-controller.js +102 -16
- package/dist/browser-controller.js.map +1 -1
- package/dist/browser-plugin.d.ts +20 -1
- package/dist/browser-plugin.d.ts.map +1 -1
- package/dist/browser-plugin.js +21 -1
- package/dist/browser-plugin.js.map +1 -1
- package/dist/browser-process/browser.d.ts +22 -1
- package/dist/browser-process/browser.d.ts.map +1 -1
- package/dist/browser-process/browser.js +77 -5
- package/dist/browser-process/browser.js.map +1 -1
- package/dist/browser-profiles/chrome/default.d.ts +116 -0
- package/dist/browser-profiles/chrome/default.d.ts.map +1 -1
- package/dist/browser-profiles/chrome/default.js +118 -1
- package/dist/browser-profiles/chrome/default.js.map +1 -1
- package/dist/browser-profiles/chrome/populate-profile.d.ts +76 -0
- package/dist/browser-profiles/chrome/populate-profile.d.ts.map +1 -0
- package/dist/browser-profiles/chrome/populate-profile.js +300 -0
- package/dist/browser-profiles/chrome/populate-profile.js.map +1 -0
- package/dist/browser-profiles/index.d.ts +1 -0
- package/dist/browser-profiles/index.d.ts.map +1 -1
- package/dist/browser-profiles/index.js +2 -0
- package/dist/browser-profiles/index.js.map +1 -1
- package/dist/crawler.d.ts +32 -1
- package/dist/crawler.d.ts.map +1 -1
- package/dist/crawler.js +7 -0
- package/dist/crawler.js.map +1 -1
- package/dist/fingerprinting/custom-fingerprint-injector.d.ts +87 -0
- package/dist/fingerprinting/custom-fingerprint-injector.d.ts.map +1 -0
- package/dist/fingerprinting/custom-fingerprint-injector.js +342 -0
- package/dist/fingerprinting/custom-fingerprint-injector.js.map +1 -0
- package/dist/fingerprinting/fingerprint-injector.d.ts +40 -2
- package/dist/fingerprinting/fingerprint-injector.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-injector.js +452 -44
- package/dist/fingerprinting/fingerprint-injector.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/audio-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/audio-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/audio-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/canvas-protection.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/canvas-protection.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/canvas-protection.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/cdp-detection-bypass.d.ts +14 -0
- package/dist/fingerprinting/fingerprint-overrides/cdp-detection-bypass.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/cdp-detection-bypass.js +776 -0
- package/dist/fingerprinting/fingerprint-overrides/cdp-detection-bypass.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/client-rect-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/client-rect-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/client-rect-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/datadome-bypass.d.ts +14 -0
- package/dist/fingerprinting/fingerprint-overrides/datadome-bypass.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/datadome-bypass.js +643 -0
- package/dist/fingerprinting/fingerprint-overrides/datadome-bypass.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/font-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/font-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/font-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/index.d.ts +17 -1
- package/dist/fingerprinting/fingerprint-overrides/index.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/index.js +21 -1
- package/dist/fingerprinting/fingerprint-overrides/index.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/keyboard-humanization.d.ts +45 -0
- package/dist/fingerprinting/fingerprint-overrides/keyboard-humanization.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/keyboard-humanization.js +291 -0
- package/dist/fingerprinting/fingerprint-overrides/keyboard-humanization.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/locale-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/locale-spoofing.js +153 -90
- package/dist/fingerprinting/fingerprint-overrides/locale-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/mouse-humanization.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/mouse-humanization.js +4 -5
- package/dist/fingerprinting/fingerprint-overrides/mouse-humanization.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/performance-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/performance-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/performance-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/platform-consistency.d.ts +13 -0
- package/dist/fingerprinting/fingerprint-overrides/platform-consistency.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/platform-consistency.js +413 -70
- package/dist/fingerprinting/fingerprint-overrides/platform-consistency.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/prototype-integrity.d.ts +13 -0
- package/dist/fingerprinting/fingerprint-overrides/prototype-integrity.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/prototype-integrity.js +355 -0
- package/dist/fingerprinting/fingerprint-overrides/prototype-integrity.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/runtime-enable-bypass.d.ts +12 -3
- package/dist/fingerprinting/fingerprint-overrides/runtime-enable-bypass.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/runtime-enable-bypass.js +261 -71
- package/dist/fingerprinting/fingerprint-overrides/runtime-enable-bypass.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/scroll-humanization.d.ts +55 -0
- package/dist/fingerprinting/fingerprint-overrides/scroll-humanization.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/scroll-humanization.js +380 -0
- package/dist/fingerprinting/fingerprint-overrides/scroll-humanization.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/stealth-script.d.ts +8 -0
- package/dist/fingerprinting/fingerprint-overrides/stealth-script.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/stealth-script.js +756 -71
- package/dist/fingerprinting/fingerprint-overrides/stealth-script.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/storage-consistency.d.ts +13 -0
- package/dist/fingerprinting/fingerprint-overrides/storage-consistency.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/storage-consistency.js +368 -0
- package/dist/fingerprinting/fingerprint-overrides/storage-consistency.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/timing-consistency.d.ts +13 -0
- package/dist/fingerprinting/fingerprint-overrides/timing-consistency.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/timing-consistency.js +438 -0
- package/dist/fingerprinting/fingerprint-overrides/timing-consistency.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/ua-ch.d.ts +7 -1
- package/dist/fingerprinting/fingerprint-overrides/ua-ch.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/ua-ch.js +158 -58
- package/dist/fingerprinting/fingerprint-overrides/ua-ch.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/utils.d.ts +12 -0
- package/dist/fingerprinting/fingerprint-overrides/utils.d.ts.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/utils.js +517 -0
- package/dist/fingerprinting/fingerprint-overrides/utils.js.map +1 -0
- package/dist/fingerprinting/fingerprint-overrides/webgl-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/webgl-spoofing.js +51 -10
- package/dist/fingerprinting/fingerprint-overrides/webgl-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/webgpu-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/webgpu-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/webgpu-spoofing.js.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/webrtc-spoofing.d.ts.map +1 -1
- package/dist/fingerprinting/fingerprint-overrides/webrtc-spoofing.js +11 -1
- package/dist/fingerprinting/fingerprint-overrides/webrtc-spoofing.js.map +1 -1
- package/dist/page.d.ts +12 -0
- package/dist/page.d.ts.map +1 -1
- package/dist/page.js +35 -3
- package/dist/page.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +4 -4
- package/dist/fingerprinting/canvas-fingerprint.d.ts +0 -4
- package/dist/fingerprinting/canvas-fingerprint.d.ts.map +0 -1
- package/dist/fingerprinting/canvas-fingerprint.js +0 -60
- package/dist/fingerprinting/canvas-fingerprint.js.map +0 -1
|
@@ -0,0 +1,517 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Stealth Utility Functions
|
|
3
|
+
*
|
|
4
|
+
* Similar to puppeteer-extra-plugin-stealth's utils.js
|
|
5
|
+
* Provides helper functions for overriding browser properties without detection.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Creates a stealth utilities script that can be injected into the browser.
|
|
9
|
+
* This script provides helper functions for property overrides that hide their tracks.
|
|
10
|
+
*/
|
|
11
|
+
export const createStealthUtilsScript = () => {
|
|
12
|
+
return `
|
|
13
|
+
(() => {
|
|
14
|
+
'use strict';
|
|
15
|
+
|
|
16
|
+
// Skip if already initialized
|
|
17
|
+
if (window.__STEALTH_UTILS_INITIALIZED__) return;
|
|
18
|
+
window.__STEALTH_UTILS_INITIALIZED__ = true;
|
|
19
|
+
|
|
20
|
+
// ============================================
|
|
21
|
+
// STEALTH UTILITIES - Hide Property Overrides
|
|
22
|
+
// ============================================
|
|
23
|
+
|
|
24
|
+
// Cache original toString BEFORE any modifications
|
|
25
|
+
const nativeToStringFunctionString = Function.prototype.toString.call(Function.prototype.toString);
|
|
26
|
+
const nativeToStringFunc = Function.prototype.toString;
|
|
27
|
+
const nativeCall = Function.prototype.call;
|
|
28
|
+
const nativeApply = Function.prototype.apply;
|
|
29
|
+
const nativeBind = Function.prototype.bind;
|
|
30
|
+
|
|
31
|
+
// WeakMap to track which functions should appear native
|
|
32
|
+
const nativeFunctionOverrides = new WeakMap();
|
|
33
|
+
|
|
34
|
+
// Track bound functions to their originals
|
|
35
|
+
const boundFunctionMap = new WeakMap();
|
|
36
|
+
|
|
37
|
+
// Track proxy targets
|
|
38
|
+
const proxyTargetMap = new WeakMap();
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Generate a native-looking function string
|
|
42
|
+
* Handles various function types for maximum authenticity
|
|
43
|
+
*/
|
|
44
|
+
const makeNativeString = (name = '', type = 'function') => {
|
|
45
|
+
// Clean the name - remove "bound " prefix if present
|
|
46
|
+
const cleanName = name.replace(/^bound /, '');
|
|
47
|
+
|
|
48
|
+
// Different native string formats
|
|
49
|
+
if (type === 'getter') {
|
|
50
|
+
return \`function get \${cleanName}() { [native code] }\`;
|
|
51
|
+
}
|
|
52
|
+
if (type === 'setter') {
|
|
53
|
+
return \`function set \${cleanName}() { [native code] }\`;
|
|
54
|
+
}
|
|
55
|
+
if (type === 'async') {
|
|
56
|
+
return \`async function \${cleanName}() { [native code] }\`;
|
|
57
|
+
}
|
|
58
|
+
if (type === 'generator') {
|
|
59
|
+
return \`function* \${cleanName}() { [native code] }\`;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
return \`function \${cleanName}() { [native code] }\`;
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Register a function to appear native when toString is called
|
|
67
|
+
* Enhanced to handle bound functions and proxies
|
|
68
|
+
*/
|
|
69
|
+
const registerNativeFunction = (fn, name = '', type = 'function') => {
|
|
70
|
+
if (typeof fn !== 'function') return;
|
|
71
|
+
|
|
72
|
+
nativeFunctionOverrides.set(fn, { name, type });
|
|
73
|
+
|
|
74
|
+
// Also register any bound versions
|
|
75
|
+
try {
|
|
76
|
+
const boundVersion = fn.bind(null);
|
|
77
|
+
if (boundVersion !== fn) {
|
|
78
|
+
boundFunctionMap.set(boundVersion, fn);
|
|
79
|
+
}
|
|
80
|
+
} catch (e) {
|
|
81
|
+
// Some functions can't be bound, ignore
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Check if a function is a Proxy
|
|
87
|
+
*/
|
|
88
|
+
const isProxy = (fn) => {
|
|
89
|
+
try {
|
|
90
|
+
// Proxies throw when you try to get their prototype in certain ways
|
|
91
|
+
return proxyTargetMap.has(fn);
|
|
92
|
+
} catch (e) {
|
|
93
|
+
return false;
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Register a Proxy and its target for toString lookup
|
|
99
|
+
*/
|
|
100
|
+
const registerProxyTarget = (proxy, target, name = '') => {
|
|
101
|
+
proxyTargetMap.set(proxy, { target, name });
|
|
102
|
+
registerNativeFunction(proxy, name);
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* Patch Function.prototype.toString to hide overridden functions
|
|
107
|
+
* Enhanced with multiple levels of protection
|
|
108
|
+
*/
|
|
109
|
+
const patchToString = () => {
|
|
110
|
+
const patchedToString = function() {
|
|
111
|
+
// Handle registered native functions
|
|
112
|
+
if (nativeFunctionOverrides.has(this)) {
|
|
113
|
+
const info = nativeFunctionOverrides.get(this);
|
|
114
|
+
return makeNativeString(info.name, info.type);
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
// Handle bound functions - look up original
|
|
118
|
+
if (boundFunctionMap.has(this)) {
|
|
119
|
+
const original = boundFunctionMap.get(this);
|
|
120
|
+
if (nativeFunctionOverrides.has(original)) {
|
|
121
|
+
const info = nativeFunctionOverrides.get(original);
|
|
122
|
+
return makeNativeString(info.name, info.type);
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// Handle proxies
|
|
127
|
+
if (proxyTargetMap.has(this)) {
|
|
128
|
+
const { target, name } = proxyTargetMap.get(this);
|
|
129
|
+
if (name) {
|
|
130
|
+
return makeNativeString(name);
|
|
131
|
+
}
|
|
132
|
+
if (target && nativeFunctionOverrides.has(target)) {
|
|
133
|
+
const info = nativeFunctionOverrides.get(target);
|
|
134
|
+
return makeNativeString(info.name, info.type);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// Check if this is an anonymous arrow function that should look native
|
|
139
|
+
// Arrow functions have no prototype property
|
|
140
|
+
const result = nativeCall.call(nativeToStringFunc, this);
|
|
141
|
+
|
|
142
|
+
// Clean result to remove CDP/automation markers
|
|
143
|
+
if (typeof result === 'string') {
|
|
144
|
+
// Remove sourceURL comments
|
|
145
|
+
let cleaned = result
|
|
146
|
+
.replace(/\\/\\/# sourceURL=[^\\n]*/g, '')
|
|
147
|
+
.replace(/\\/\\/# sourceMappingURL=[^\\n]*/g, '')
|
|
148
|
+
.replace(/__puppeteer_evaluation_script__/g, '')
|
|
149
|
+
.replace(/__playwright_evaluation_script__/g, '')
|
|
150
|
+
.replace(/pptr:[^\\n]*/g, '');
|
|
151
|
+
|
|
152
|
+
return cleaned;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
return result;
|
|
156
|
+
};
|
|
157
|
+
|
|
158
|
+
// Make patchedToString itself appear native
|
|
159
|
+
nativeFunctionOverrides.set(patchedToString, { name: 'toString', type: 'function' });
|
|
160
|
+
|
|
161
|
+
// Replace Function.prototype.toString
|
|
162
|
+
Function.prototype.toString = patchedToString;
|
|
163
|
+
|
|
164
|
+
// Patch toString.call and toString.apply to use our version
|
|
165
|
+
// CRITICAL: Bypass patchedToString completely - call nativeToStringFunc directly
|
|
166
|
+
// to prevent infinite recursion when scripts call toString.call.call() etc.
|
|
167
|
+
const patchedCall = function(thisArg, ...args) {
|
|
168
|
+
// Handle our registered overrides first
|
|
169
|
+
if (thisArg && nativeFunctionOverrides.has(thisArg)) {
|
|
170
|
+
const info = nativeFunctionOverrides.get(thisArg);
|
|
171
|
+
return makeNativeString(info.name, info.type);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
// Handle bound functions
|
|
175
|
+
if (thisArg && boundFunctionMap.has(thisArg)) {
|
|
176
|
+
const original = boundFunctionMap.get(thisArg);
|
|
177
|
+
if (nativeFunctionOverrides.has(original)) {
|
|
178
|
+
const info = nativeFunctionOverrides.get(original);
|
|
179
|
+
return makeNativeString(info.name, info.type);
|
|
180
|
+
}
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
// Handle proxies
|
|
184
|
+
if (thisArg && proxyTargetMap.has(thisArg)) {
|
|
185
|
+
const { target, name } = proxyTargetMap.get(thisArg);
|
|
186
|
+
if (name) return makeNativeString(name);
|
|
187
|
+
if (target && nativeFunctionOverrides.has(target)) {
|
|
188
|
+
const info = nativeFunctionOverrides.get(target);
|
|
189
|
+
return makeNativeString(info.name, info.type);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
// CRITICAL: Call native toString directly to avoid any recursion
|
|
194
|
+
// Never go through patchedToString from here
|
|
195
|
+
return nativeCall.call(nativeToStringFunc, thisArg);
|
|
196
|
+
};
|
|
197
|
+
|
|
198
|
+
const patchedApply = function(thisArg, argsArray) {
|
|
199
|
+
// Handle our registered overrides first
|
|
200
|
+
if (thisArg && nativeFunctionOverrides.has(thisArg)) {
|
|
201
|
+
const info = nativeFunctionOverrides.get(thisArg);
|
|
202
|
+
return makeNativeString(info.name, info.type);
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
// Handle bound functions
|
|
206
|
+
if (thisArg && boundFunctionMap.has(thisArg)) {
|
|
207
|
+
const original = boundFunctionMap.get(thisArg);
|
|
208
|
+
if (nativeFunctionOverrides.has(original)) {
|
|
209
|
+
const info = nativeFunctionOverrides.get(original);
|
|
210
|
+
return makeNativeString(info.name, info.type);
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
// Handle proxies
|
|
215
|
+
if (thisArg && proxyTargetMap.has(thisArg)) {
|
|
216
|
+
const { target, name } = proxyTargetMap.get(thisArg);
|
|
217
|
+
if (name) return makeNativeString(name);
|
|
218
|
+
if (target && nativeFunctionOverrides.has(target)) {
|
|
219
|
+
const info = nativeFunctionOverrides.get(target);
|
|
220
|
+
return makeNativeString(info.name, info.type);
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
// CRITICAL: Call native toString directly to avoid any recursion
|
|
225
|
+
return nativeCall.call(nativeToStringFunc, thisArg);
|
|
226
|
+
};
|
|
227
|
+
|
|
228
|
+
// Register call/apply as native
|
|
229
|
+
nativeFunctionOverrides.set(patchedCall, { name: 'call', type: 'function' });
|
|
230
|
+
nativeFunctionOverrides.set(patchedApply, { name: 'apply', type: 'function' });
|
|
231
|
+
|
|
232
|
+
// Make toString.toString return the native string
|
|
233
|
+
Object.defineProperty(Function.prototype.toString, 'toString', {
|
|
234
|
+
value: patchedToString,
|
|
235
|
+
writable: false,
|
|
236
|
+
configurable: false,
|
|
237
|
+
enumerable: false
|
|
238
|
+
});
|
|
239
|
+
|
|
240
|
+
// Patch call and apply on our toString
|
|
241
|
+
Object.defineProperty(Function.prototype.toString, 'call', {
|
|
242
|
+
value: patchedCall,
|
|
243
|
+
writable: false,
|
|
244
|
+
configurable: false,
|
|
245
|
+
enumerable: false
|
|
246
|
+
});
|
|
247
|
+
|
|
248
|
+
Object.defineProperty(Function.prototype.toString, 'apply', {
|
|
249
|
+
value: patchedApply,
|
|
250
|
+
writable: false,
|
|
251
|
+
configurable: false,
|
|
252
|
+
enumerable: false
|
|
253
|
+
});
|
|
254
|
+
|
|
255
|
+
// Also protect against Function.prototype.toString.bind()
|
|
256
|
+
const originalBind = Function.prototype.toString.bind;
|
|
257
|
+
Object.defineProperty(Function.prototype.toString, 'bind', {
|
|
258
|
+
value: function(...args) {
|
|
259
|
+
const bound = nativeBind.apply(patchedToString, args);
|
|
260
|
+
nativeFunctionOverrides.set(bound, { name: 'toString', type: 'function' });
|
|
261
|
+
boundFunctionMap.set(bound, patchedToString);
|
|
262
|
+
return bound;
|
|
263
|
+
},
|
|
264
|
+
writable: false,
|
|
265
|
+
configurable: false,
|
|
266
|
+
enumerable: false
|
|
267
|
+
});
|
|
268
|
+
};
|
|
269
|
+
|
|
270
|
+
/**
|
|
271
|
+
* Check if a property can be redefined on an object
|
|
272
|
+
*/
|
|
273
|
+
const canRedefineProperty = (obj, prop) => {
|
|
274
|
+
try {
|
|
275
|
+
const descriptor = Object.getOwnPropertyDescriptor(obj, prop);
|
|
276
|
+
// Property doesn't exist or is configurable
|
|
277
|
+
return !descriptor || descriptor.configurable !== false;
|
|
278
|
+
} catch (e) {
|
|
279
|
+
return false;
|
|
280
|
+
}
|
|
281
|
+
};
|
|
282
|
+
|
|
283
|
+
/**
|
|
284
|
+
* Safely override a property with guards
|
|
285
|
+
* Returns true if successful, false otherwise
|
|
286
|
+
*/
|
|
287
|
+
const overridePropertyWithGuard = (obj, prop, descriptor) => {
|
|
288
|
+
if (!canRedefineProperty(obj, prop)) {
|
|
289
|
+
return false;
|
|
290
|
+
}
|
|
291
|
+
try {
|
|
292
|
+
Object.defineProperty(obj, prop, descriptor);
|
|
293
|
+
return true;
|
|
294
|
+
} catch (e) {
|
|
295
|
+
return false;
|
|
296
|
+
}
|
|
297
|
+
};
|
|
298
|
+
|
|
299
|
+
/**
|
|
300
|
+
* Override a getter property and make the getter appear native
|
|
301
|
+
*/
|
|
302
|
+
const overrideGetterWithNative = (obj, prop, getter, name = '') => {
|
|
303
|
+
// Register the getter to appear native
|
|
304
|
+
registerNativeFunction(getter, name || \`get \${prop}\`);
|
|
305
|
+
|
|
306
|
+
return overridePropertyWithGuard(obj, prop, {
|
|
307
|
+
get: getter,
|
|
308
|
+
configurable: true,
|
|
309
|
+
enumerable: true
|
|
310
|
+
});
|
|
311
|
+
};
|
|
312
|
+
|
|
313
|
+
/**
|
|
314
|
+
* Create a proxy handler that makes all accessed functions appear native
|
|
315
|
+
*/
|
|
316
|
+
const createNativeProxyHandler = (targetName = '') => {
|
|
317
|
+
return {
|
|
318
|
+
get(target, property, receiver) {
|
|
319
|
+
const value = Reflect.get(target, property, receiver);
|
|
320
|
+
|
|
321
|
+
// Bind functions to target and register as native
|
|
322
|
+
if (typeof value === 'function') {
|
|
323
|
+
const bound = value.bind(target);
|
|
324
|
+
registerNativeFunction(bound, value.name || property);
|
|
325
|
+
return bound;
|
|
326
|
+
}
|
|
327
|
+
|
|
328
|
+
return value;
|
|
329
|
+
},
|
|
330
|
+
|
|
331
|
+
// Make the proxy's toString appear native
|
|
332
|
+
apply(target, thisArg, args) {
|
|
333
|
+
return Reflect.apply(target, thisArg, args);
|
|
334
|
+
}
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
|
|
338
|
+
/**
|
|
339
|
+
* Cache original property value before overriding
|
|
340
|
+
* This prevents infinite recursion when getter calls itself
|
|
341
|
+
*/
|
|
342
|
+
const cacheAndOverride = (obj, prop, transformFn) => {
|
|
343
|
+
// Cache the original value BEFORE any override
|
|
344
|
+
let originalValue;
|
|
345
|
+
try {
|
|
346
|
+
originalValue = obj[prop];
|
|
347
|
+
} catch (e) {
|
|
348
|
+
originalValue = undefined;
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
// Create getter that uses cached value
|
|
352
|
+
const getter = function() {
|
|
353
|
+
return transformFn(originalValue);
|
|
354
|
+
};
|
|
355
|
+
|
|
356
|
+
return overrideGetterWithNative(obj, prop, getter, \`get \${prop}\`);
|
|
357
|
+
};
|
|
358
|
+
|
|
359
|
+
/**
|
|
360
|
+
* Log property override success
|
|
361
|
+
*/
|
|
362
|
+
const logPropertyOverride = (objName, propName, value, success = true) => {
|
|
363
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
364
|
+
const ERROR_PREFIX = '[CDP-FP-ERROR]';
|
|
365
|
+
|
|
366
|
+
if (success) {
|
|
367
|
+
console.log(DEBUG_PREFIX, \`✓ Overridden \${objName}.\${propName} to:\`, value);
|
|
368
|
+
} else {
|
|
369
|
+
console.warn(ERROR_PREFIX, \`⚠ Failed to override \${objName}.\${propName}\`);
|
|
370
|
+
}
|
|
371
|
+
};
|
|
372
|
+
|
|
373
|
+
/**
|
|
374
|
+
* Verify that a property override was successful
|
|
375
|
+
*/
|
|
376
|
+
const verifyOverride = (obj, objName, propName, expectedValue) => {
|
|
377
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
378
|
+
try {
|
|
379
|
+
const actualValue = obj[propName];
|
|
380
|
+
const matches = JSON.stringify(actualValue) === JSON.stringify(expectedValue);
|
|
381
|
+
|
|
382
|
+
if (matches) {
|
|
383
|
+
console.log(DEBUG_PREFIX, \`✓ Verified \${objName}.\${propName}\`);
|
|
384
|
+
} else {
|
|
385
|
+
console.warn(DEBUG_PREFIX, \`⚠ Mismatch for \${objName}.\${propName}: expected\`, expectedValue, 'got', actualValue);
|
|
386
|
+
}
|
|
387
|
+
|
|
388
|
+
return matches;
|
|
389
|
+
} catch (error) {
|
|
390
|
+
console.error(DEBUG_PREFIX, \`Error verifying \${objName}.\${propName}:\`, error);
|
|
391
|
+
return false;
|
|
392
|
+
}
|
|
393
|
+
};
|
|
394
|
+
|
|
395
|
+
/**
|
|
396
|
+
* Handle frozen properties using Proxy fallback (puppeteer-stealth style)
|
|
397
|
+
*/
|
|
398
|
+
const handleFrozenProperty = (obj, prop, value) => {
|
|
399
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
400
|
+
const ERROR_PREFIX = '[CDP-FP-ERROR]';
|
|
401
|
+
|
|
402
|
+
try {
|
|
403
|
+
const descriptor = Object.getOwnPropertyDescriptor(obj, prop);
|
|
404
|
+
|
|
405
|
+
// If property is frozen (configurable: false), use Proxy approach
|
|
406
|
+
if (descriptor && descriptor.configurable === false) {
|
|
407
|
+
console.warn(DEBUG_PREFIX, \`Property is frozen: \${prop}, attempting Proxy fallback\`);
|
|
408
|
+
|
|
409
|
+
// Strategy 1: Try to redefine on the prototype
|
|
410
|
+
const proto = Object.getPrototypeOf(obj);
|
|
411
|
+
if (proto && canRedefineProperty(proto, prop)) {
|
|
412
|
+
const getter = () => value;
|
|
413
|
+
registerNativeFunction(getter, \`get \${prop}\`);
|
|
414
|
+
|
|
415
|
+
Object.defineProperty(proto, prop, {
|
|
416
|
+
get: getter,
|
|
417
|
+
configurable: true,
|
|
418
|
+
enumerable: true
|
|
419
|
+
});
|
|
420
|
+
|
|
421
|
+
console.log(DEBUG_PREFIX, \`✓ Overridden \${prop} via prototype\`);
|
|
422
|
+
return true;
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
// Strategy 2: Log that we cannot override
|
|
426
|
+
console.warn(ERROR_PREFIX, \`Cannot override frozen property: \${prop}\`);
|
|
427
|
+
return false;
|
|
428
|
+
}
|
|
429
|
+
|
|
430
|
+
// Property is configurable, use normal override
|
|
431
|
+
return false; // Let caller handle normal override
|
|
432
|
+
} catch (error) {
|
|
433
|
+
console.error(ERROR_PREFIX, \`Error handling frozen property \${prop}:\`, error);
|
|
434
|
+
return false;
|
|
435
|
+
}
|
|
436
|
+
};
|
|
437
|
+
|
|
438
|
+
/**
|
|
439
|
+
* Wrap a function with error boundary that logs errors
|
|
440
|
+
*/
|
|
441
|
+
const withErrorBoundary = (fn, fnName = 'anonymous') => {
|
|
442
|
+
return function(...args) {
|
|
443
|
+
const ERROR_PREFIX = '[CDP-FP-ERROR]';
|
|
444
|
+
try {
|
|
445
|
+
return fn.apply(this, args);
|
|
446
|
+
} catch (error) {
|
|
447
|
+
console.error(ERROR_PREFIX, \`Error in \${fnName}:\`, error);
|
|
448
|
+
throw error; // Re-throw to make errors visible
|
|
449
|
+
}
|
|
450
|
+
};
|
|
451
|
+
};
|
|
452
|
+
|
|
453
|
+
/**
|
|
454
|
+
* Enhanced override with frozen property handling and logging
|
|
455
|
+
*/
|
|
456
|
+
const overridePropertySafe = (obj, objName, prop, value) => {
|
|
457
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
458
|
+
|
|
459
|
+
// First, check if property is frozen
|
|
460
|
+
const descriptor = Object.getOwnPropertyDescriptor(obj, prop);
|
|
461
|
+
if (descriptor && descriptor.configurable === false) {
|
|
462
|
+
console.warn(DEBUG_PREFIX, \`⚠ Property \${objName}.\${prop} is frozen\`);
|
|
463
|
+
|
|
464
|
+
// Attempt frozen property handling
|
|
465
|
+
const handled = handleFrozenProperty(obj, prop, value);
|
|
466
|
+
if (handled) {
|
|
467
|
+
logPropertyOverride(objName, prop, value, true);
|
|
468
|
+
return true;
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
logPropertyOverride(objName, prop, value, false);
|
|
472
|
+
return false;
|
|
473
|
+
}
|
|
474
|
+
|
|
475
|
+
// Property is configurable, override normally
|
|
476
|
+
const getter = () => value;
|
|
477
|
+
registerNativeFunction(getter, \`get \${prop}\`);
|
|
478
|
+
|
|
479
|
+
const success = overridePropertyWithGuard(obj, prop, {
|
|
480
|
+
get: getter,
|
|
481
|
+
configurable: true,
|
|
482
|
+
enumerable: true
|
|
483
|
+
});
|
|
484
|
+
|
|
485
|
+
logPropertyOverride(objName, prop, value, success);
|
|
486
|
+
return success;
|
|
487
|
+
};
|
|
488
|
+
|
|
489
|
+
// Initialize toString patch immediately
|
|
490
|
+
patchToString();
|
|
491
|
+
|
|
492
|
+
// Export utilities to global scope for use by other scripts
|
|
493
|
+
window.__stealthUtils__ = {
|
|
494
|
+
makeNativeString,
|
|
495
|
+
registerNativeFunction,
|
|
496
|
+
registerProxyTarget,
|
|
497
|
+
canRedefineProperty,
|
|
498
|
+
overridePropertyWithGuard,
|
|
499
|
+
overrideGetterWithNative,
|
|
500
|
+
createNativeProxyHandler,
|
|
501
|
+
cacheAndOverride,
|
|
502
|
+
nativeFunctionOverrides,
|
|
503
|
+
boundFunctionMap,
|
|
504
|
+
proxyTargetMap,
|
|
505
|
+
// New logging and safety utilities
|
|
506
|
+
logPropertyOverride,
|
|
507
|
+
verifyOverride,
|
|
508
|
+
handleFrozenProperty,
|
|
509
|
+
withErrorBoundary,
|
|
510
|
+
overridePropertySafe
|
|
511
|
+
};
|
|
512
|
+
|
|
513
|
+
console.log('[CDP-FP-DEBUG] ✓ Stealth utilities initialized with enhanced toString masking');
|
|
514
|
+
})();
|
|
515
|
+
`;
|
|
516
|
+
};
|
|
517
|
+
//# sourceMappingURL=utils.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/utils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;;GAGG;AACH,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAW,EAAE;IACjD,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAufV,CAAC;AACF,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webgl-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgl-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,WAAW;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,yBAAyB,sBAAuB,WAAW,KAAG,
|
|
1
|
+
{"version":3,"file":"webgl-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgl-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,WAAW,WAAW;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC7B;AAED,eAAO,MAAM,yBAAyB,sBAAuB,WAAW,KAAG,MA2M1E,CAAC"}
|
|
@@ -20,44 +20,75 @@ export const createWebGLSpoofingScript = (fingerprintWebGL) => {
|
|
|
20
20
|
const fingerprintConfig = ${JSON.stringify(fingerprintWebGL)};
|
|
21
21
|
const selectedVendor = fingerprintConfig.vendorUnmasked || fingerprintConfig.vendor || 'Intel Inc.';
|
|
22
22
|
const selectedRenderer = fingerprintConfig.rendererUnmasked || fingerprintConfig.renderer || 'Intel Iris OpenGL Engine';
|
|
23
|
+
console.log('[CDP-FP-DEBUG] WebGL using fingerprint data - Vendor:', selectedVendor, 'Renderer:', selectedRenderer.substring(0, 50));
|
|
23
24
|
` : `
|
|
24
25
|
// Detect platform from navigator
|
|
25
|
-
const platform = navigator.platform || '
|
|
26
|
+
const platform = navigator.platform || 'Win32';
|
|
26
27
|
|
|
27
|
-
// Platform-specific GPU configurations
|
|
28
|
+
// Platform-specific GPU configurations - 2024-2025 updated
|
|
29
|
+
// IMPORTANT: Windows GPU strings must follow the exact Chrome ANGLE format
|
|
28
30
|
const gpuConfigs = {
|
|
29
31
|
'Win32': {
|
|
30
|
-
|
|
32
|
+
// Windows uses "Google Inc. (VENDOR)" format for vendor
|
|
33
|
+
vendors: [
|
|
34
|
+
'Google Inc. (NVIDIA)',
|
|
35
|
+
'Google Inc. (AMD)',
|
|
36
|
+
'Google Inc. (Intel)'
|
|
37
|
+
],
|
|
38
|
+
// Windows renderers use Direct3D11 format - authentic Chrome strings
|
|
31
39
|
renderers: [
|
|
32
40
|
'ANGLE (NVIDIA, NVIDIA GeForce GTX 1660 Ti Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
33
41
|
'ANGLE (NVIDIA, NVIDIA GeForce RTX 3060 Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
42
|
+
'ANGLE (NVIDIA, NVIDIA GeForce RTX 4070 Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
43
|
+
'ANGLE (AMD, AMD Radeon RX 6700 XT Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
34
44
|
'ANGLE (AMD, AMD Radeon RX 6600 Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
35
45
|
'ANGLE (Intel, Intel(R) UHD Graphics 630 Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
46
|
+
'ANGLE (Intel, Intel(R) Iris(R) Xe Graphics Direct3D11 vs_5_0 ps_5_0, D3D11)',
|
|
47
|
+
],
|
|
48
|
+
vendorPairs: [
|
|
49
|
+
{ vendor: 'Google Inc. (NVIDIA)', renderer: 'ANGLE (NVIDIA, NVIDIA GeForce GTX 1660 Ti Direct3D11 vs_5_0 ps_5_0, D3D11)' },
|
|
50
|
+
{ vendor: 'Google Inc. (NVIDIA)', renderer: 'ANGLE (NVIDIA, NVIDIA GeForce RTX 3060 Direct3D11 vs_5_0 ps_5_0, D3D11)' },
|
|
51
|
+
{ vendor: 'Google Inc. (AMD)', renderer: 'ANGLE (AMD, AMD Radeon RX 6700 XT Direct3D11 vs_5_0 ps_5_0, D3D11)' },
|
|
52
|
+
{ vendor: 'Google Inc. (Intel)', renderer: 'ANGLE (Intel, Intel(R) UHD Graphics 630 Direct3D11 vs_5_0 ps_5_0, D3D11)' },
|
|
36
53
|
],
|
|
37
54
|
},
|
|
38
55
|
'MacIntel': {
|
|
39
|
-
vendors: ['
|
|
56
|
+
vendors: ['Google Inc. (Apple)', 'Google Inc. (Intel)', 'Google Inc. (AMD)'],
|
|
40
57
|
renderers: [
|
|
41
58
|
'ANGLE (Apple, Apple M1 Pro, OpenGL 4.1)',
|
|
42
59
|
'ANGLE (Apple, Apple M2, OpenGL 4.1)',
|
|
43
60
|
'ANGLE (Intel Inc., Intel(R) Iris(TM) Plus Graphics OpenGL Engine, OpenGL 4.1)',
|
|
44
61
|
'ANGLE (AMD, AMD Radeon Pro 5500M OpenGL Engine, OpenGL 4.1)',
|
|
45
62
|
],
|
|
63
|
+
vendorPairs: [
|
|
64
|
+
{ vendor: 'Google Inc. (Apple)', renderer: 'ANGLE (Apple, Apple M1 Pro, OpenGL 4.1)' },
|
|
65
|
+
{ vendor: 'Google Inc. (Intel)', renderer: 'ANGLE (Intel Inc., Intel(R) Iris(TM) Plus Graphics OpenGL Engine, OpenGL 4.1)' },
|
|
66
|
+
],
|
|
46
67
|
},
|
|
47
68
|
'Linux x86_64': {
|
|
48
|
-
vendors: ['Intel', 'NVIDIA
|
|
69
|
+
vendors: ['Google Inc. (Intel)', 'Google Inc. (NVIDIA)', 'Google Inc. (AMD)'],
|
|
49
70
|
renderers: [
|
|
50
71
|
'ANGLE (Intel, Mesa Intel(R) UHD Graphics 630 (CFL GT2), OpenGL 4.6)',
|
|
51
72
|
'ANGLE (NVIDIA, NVIDIA GeForce GTX 1660 Ti/PCIe/SSE2, OpenGL 4.6)',
|
|
52
73
|
'ANGLE (AMD, AMD Radeon RX 6600 (NAVY_FLOUNDER, DRM 3.42.0, 5.15.0-56-generic, LLVM 12.0.0), OpenGL 4.6)',
|
|
53
|
-
|
|
74
|
+
],
|
|
75
|
+
vendorPairs: [
|
|
76
|
+
{ vendor: 'Google Inc. (Intel)', renderer: 'ANGLE (Intel, Mesa Intel(R) UHD Graphics 630 (CFL GT2), OpenGL 4.6)' },
|
|
77
|
+
{ vendor: 'Google Inc. (NVIDIA)', renderer: 'ANGLE (NVIDIA, NVIDIA GeForce GTX 1660 Ti/PCIe/SSE2, OpenGL 4.6)' },
|
|
54
78
|
],
|
|
55
79
|
},
|
|
56
80
|
};
|
|
57
81
|
|
|
58
|
-
|
|
59
|
-
const
|
|
60
|
-
|
|
82
|
+
// Default to Windows for better anti-bot evasion (most common platform)
|
|
83
|
+
const config = gpuConfigs[platform] || gpuConfigs['Win32'];
|
|
84
|
+
|
|
85
|
+
// Select a consistent vendor/renderer pair
|
|
86
|
+
const pairIndex = Math.floor(Math.random() * config.vendorPairs.length);
|
|
87
|
+
const selectedPair = config.vendorPairs[pairIndex];
|
|
88
|
+
const selectedVendor = selectedPair.vendor;
|
|
89
|
+
const selectedRenderer = selectedPair.renderer;
|
|
90
|
+
|
|
91
|
+
console.log('[CDP-FP-DEBUG] WebGL using platform:', platform, '- Vendor:', selectedVendor, 'Renderer:', selectedRenderer.substring(0, 60) + '...');
|
|
61
92
|
`}
|
|
62
93
|
|
|
63
94
|
// Override getParameter
|
|
@@ -161,7 +192,17 @@ export const createWebGLSpoofingScript = (fingerprintWebGL) => {
|
|
|
161
192
|
}
|
|
162
193
|
};
|
|
163
194
|
|
|
164
|
-
|
|
195
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
196
|
+
const ERROR_PREFIX = '[CDP-FP-ERROR]';
|
|
197
|
+
|
|
198
|
+
try {
|
|
199
|
+
console.log(DEBUG_PREFIX, 'Starting WebGL spoofing...');
|
|
200
|
+
spoofWebGL();
|
|
201
|
+
console.log(DEBUG_PREFIX, '✓ WebGL spoofing applied');
|
|
202
|
+
} catch (e) {
|
|
203
|
+
console.error(ERROR_PREFIX, '✗ Failed to apply WebGL spoofing:', e);
|
|
204
|
+
throw e; // Rethrow to make errors visible
|
|
205
|
+
}
|
|
165
206
|
})();`;
|
|
166
207
|
};
|
|
167
208
|
//# sourceMappingURL=webgl-spoofing.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webgl-spoofing.js","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgl-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AASH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,gBAA8B,EAAU,EAAE;IAChF,iFAAiF;IACjF,MAAM,cAAc,GAAG,gBAAgB,IAAI,CAAC,gBAAgB,CAAC,cAAc,IAAI,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IAElH,OAAO;;;;;;;;;;UAUD,cAAc,CAAC,CAAC,CAAC;;oCAES,IAAI,CAAC,SAAS,CAAC,gBAAgB,CAAC
|
|
1
|
+
{"version":3,"file":"webgl-spoofing.js","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgl-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AASH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,gBAA8B,EAAU,EAAE;IAChF,iFAAiF;IACjF,MAAM,cAAc,GAAG,gBAAgB,IAAI,CAAC,gBAAgB,CAAC,cAAc,IAAI,gBAAgB,CAAC,gBAAgB,CAAC,CAAC;IAElH,OAAO;;;;;;;;;;UAUD,cAAc,CAAC,CAAC,CAAC;;oCAES,IAAI,CAAC,SAAS,CAAC,gBAAgB,CAAC;;;;SAI3D,CAAC,CAAC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;SAoEH;;;;;;;;;;;;;;yBAcgB,cAAc,IAAI,gBAAgB,EAAE,MAAM,CAAC,CAAC,CAAC,IAAI,gBAAgB,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,UAAU;;;yBAGxF,cAAc,IAAI,gBAAgB,EAAE,QAAQ,CAAC,CAAC,CAAC,IAAI,gBAAgB,CAAC,QAAQ,GAAG,CAAC,CAAC,CAAC,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;UA2CjH,CAAC,cAAc,CAAC,CAAC,CAAC;;;;;;;;;SASnB,CAAC,CAAC,CAAC;;SAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MA2CH,CAAC;AACP,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webgpu-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgpu-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,0BAA0B,kCAA+B,
|
|
1
|
+
{"version":3,"file":"webgpu-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgpu-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,0BAA0B,kCAA+B,MAiNrE,CAAC"}
|
|
@@ -199,7 +199,17 @@ export const createWebGPUSpoofingScript = (experimentalMode = false) => {
|
|
|
199
199
|
}
|
|
200
200
|
};
|
|
201
201
|
|
|
202
|
-
|
|
202
|
+
const DEBUG_PREFIX = '[CDP-FP-DEBUG]';
|
|
203
|
+
const ERROR_PREFIX = '[CDP-FP-ERROR]';
|
|
204
|
+
|
|
205
|
+
try {
|
|
206
|
+
console.log(DEBUG_PREFIX, 'Starting WebGPU spoofing...');
|
|
207
|
+
spoofWebGPU();
|
|
208
|
+
console.log(DEBUG_PREFIX, '✓ WebGPU spoofing applied');
|
|
209
|
+
} catch (e) {
|
|
210
|
+
console.error(ERROR_PREFIX, '✗ Failed to apply WebGPU spoofing:', e);
|
|
211
|
+
throw e;
|
|
212
|
+
}
|
|
203
213
|
})();`;
|
|
204
214
|
};
|
|
205
215
|
//# sourceMappingURL=webgpu-spoofing.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webgpu-spoofing.js","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgpu-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,gBAAgB,GAAG,KAAK,EAAU,EAAE;IAC3E,OAAO;;;;;;;UAOD,gBAAgB,CAAC,CAAC,CAAC;;;;;;;;;SASpB,CAAC,CAAC,CAAC,EAAE
|
|
1
|
+
{"version":3,"file":"webgpu-spoofing.js","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webgpu-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,gBAAgB,GAAG,KAAK,EAAU,EAAE;IAC3E,OAAO;;;;;;;UAOD,gBAAgB,CAAC,CAAC,CAAC;;;;;;;;;SASpB,CAAC,CAAC,CAAC,EAAE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MA+LR,CAAC;AACP,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"webrtc-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webrtc-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,0BAA0B,QAAO,
|
|
1
|
+
{"version":3,"file":"webrtc-spoofing.d.ts","sourceRoot":"","sources":["../../../src/fingerprinting/fingerprint-overrides/webrtc-spoofing.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,eAAO,MAAM,0BAA0B,QAAO,MAoG7C,CAAC"}
|