httpcloak 1.6.0 → 1.6.1-beta.2
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/lib/index.d.ts +10 -0
- package/lib/index.js +12 -0
- package/npm/darwin-arm64/package.json +1 -1
- package/npm/darwin-x64/package.json +1 -1
- package/npm/linux-arm64/package.json +1 -1
- package/npm/linux-x64/package.json +1 -1
- package/npm/win32-arm64/package.json +1 -1
- package/npm/win32-x64/package.json +1 -1
- package/package.json +7 -7
package/lib/index.d.ts
CHANGED
|
@@ -237,6 +237,16 @@ export interface SessionOptions {
|
|
|
237
237
|
localAddress?: string;
|
|
238
238
|
/** Path to write TLS key log for Wireshark decryption (overrides SSLKEYLOGFILE env var) */
|
|
239
239
|
keyLogFile?: string;
|
|
240
|
+
/** Enable speculative TLS optimization for proxy connections (default: false) */
|
|
241
|
+
enableSpeculativeTls?: boolean;
|
|
242
|
+
/** Protocol to switch to after Refresh() (e.g., "h1", "h2", "h3") */
|
|
243
|
+
switchProtocol?: string;
|
|
244
|
+
/** Custom JA3 fingerprint string (e.g., "771,4865-4866-4867-...,0-23-65281-...,29-23-24,0") */
|
|
245
|
+
ja3?: string;
|
|
246
|
+
/** Custom Akamai HTTP/2 fingerprint string (e.g., "1:65536;2:0;4:6291456;6:262144|15663105|0|m,a,s,p") */
|
|
247
|
+
akamai?: string;
|
|
248
|
+
/** Extra fingerprint options: { tls_alpn, tls_signature_algorithms, tls_cert_compression, tls_permute_extensions } */
|
|
249
|
+
extraFp?: Record<string, any>;
|
|
240
250
|
}
|
|
241
251
|
|
|
242
252
|
export interface RequestOptions {
|
package/lib/index.js
CHANGED
|
@@ -1272,6 +1272,9 @@ class Session {
|
|
|
1272
1272
|
keyLogFile = null,
|
|
1273
1273
|
enableSpeculativeTls = false,
|
|
1274
1274
|
switchProtocol = null,
|
|
1275
|
+
ja3 = null,
|
|
1276
|
+
akamai = null,
|
|
1277
|
+
extraFp = null,
|
|
1275
1278
|
} = options;
|
|
1276
1279
|
|
|
1277
1280
|
this._lib = getLib();
|
|
@@ -1338,6 +1341,15 @@ class Session {
|
|
|
1338
1341
|
if (switchProtocol) {
|
|
1339
1342
|
config.switch_protocol = switchProtocol;
|
|
1340
1343
|
}
|
|
1344
|
+
if (ja3) {
|
|
1345
|
+
config.ja3 = ja3;
|
|
1346
|
+
}
|
|
1347
|
+
if (akamai) {
|
|
1348
|
+
config.akamai = akamai;
|
|
1349
|
+
}
|
|
1350
|
+
if (extraFp) {
|
|
1351
|
+
config.extra_fp = extraFp;
|
|
1352
|
+
}
|
|
1341
1353
|
|
|
1342
1354
|
this._handle = this._lib.httpcloak_session_new(JSON.stringify(config));
|
|
1343
1355
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "httpcloak",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.1-beta.2",
|
|
4
4
|
"description": "Browser fingerprint emulation HTTP client with HTTP/1.1, HTTP/2, and HTTP/3 support",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/index.mjs",
|
|
@@ -49,12 +49,12 @@
|
|
|
49
49
|
"koffi": "^2.9.0"
|
|
50
50
|
},
|
|
51
51
|
"optionalDependencies": {
|
|
52
|
-
"@httpcloak/darwin-arm64": "1.6.
|
|
53
|
-
"@httpcloak/darwin-x64": "1.6.
|
|
54
|
-
"@httpcloak/linux-arm64": "1.6.
|
|
55
|
-
"@httpcloak/linux-x64": "1.6.
|
|
56
|
-
"@httpcloak/win32-arm64": "1.6.
|
|
57
|
-
"@httpcloak/win32-x64": "1.6.
|
|
52
|
+
"@httpcloak/darwin-arm64": "1.6.1-beta.2",
|
|
53
|
+
"@httpcloak/darwin-x64": "1.6.1-beta.2",
|
|
54
|
+
"@httpcloak/linux-arm64": "1.6.1-beta.2",
|
|
55
|
+
"@httpcloak/linux-x64": "1.6.1-beta.2",
|
|
56
|
+
"@httpcloak/win32-arm64": "1.6.1-beta.2",
|
|
57
|
+
"@httpcloak/win32-x64": "1.6.1-beta.2"
|
|
58
58
|
},
|
|
59
59
|
"devDependencies": {
|
|
60
60
|
"@types/node": "^25.1.0",
|