148tls-fetch
v0.1.1
Published
curl_cffi-like HTTP client with a real Chrome 148 TLS + HTTP/2 fingerprint (Rust/BoringSSL via napi-rs). Windows x64.
Maintainers
Readme
148tls-fetch
curl_cffi-like HTTP client emitting a real Chrome 148 TLS ClientHello + HTTP/2 fingerprint.
Engine: Rust (wreq / BoringSSL) compiled to a native Node addon via napi-rs.
Platform: Windows x64 only. (os: win32, cpu: x64)
Install
npm install 148tls-fetchUsage
const { CurlSession, Curl, CurlOpt, CurlInfo } = require("148tls-fetch");
const s = new CurlSession({ impersonate: "chrome148", proxy: "http://user:pass@host:port" });
const r = await s.get("https://x.com/", {
headers: { "User-Agent": "Mozilla/5.0 ... Chrome/148.0.0.0 Safari/537.36" },
timeout: 20000,
});
console.log(r.status, r.text.length);
// r = { status, url, text, data, dataRaw(Buffer), headers, headersList }
// cookies persist in s.jar across requests automatically
s.jar.setCookieSync("auth_token=...; Domain=.x.com; Path=/; Secure", "https://x.com/");
const post = await s.post("https://api.example.com/x", JSON.stringify({ a: 1 }), {
headers: { "Content-Type": "application/json" },
});Low-level handle (curl-cffi Curl style)
const c = new Curl();
c.impersonate("chrome148", false);
c.setOption(CurlOpt.Url, "https://example.com/");
c.setOption(CurlOpt.HttpGet, true);
c.setHeadersRaw(["User-Agent: ...", "Accept: application/json"]);
await c.perform();
c.status(); // HTTP status
c.getRespBody(); // Buffer
c.getInfoString(CurlInfo.EffectiveUrl); // final URL after redirects
c.close();Fingerprint
Matches real Chrome 148 on JA4, HTTP/2 Akamai, cipher list, supported groups, and extension set. (JA3 hash intentionally varies — Chrome 110+ randomizes TLS extension order each handshake; JA4 is the stable identifier.)
License
MIT
