This is an advanced NodeJS implementation of Golang's utls repository with session support provided through tough-cookie. It's syntax is similar to that of npm's popular (deprecated) request package. Additionally, it supports pseudo-header order, gzip, deflate, and brotli.
npm i turnt-tls
npm install
npm run start
Please read the following writeups for a better understanding of TLS/SSL Handshakes and why JA3 can fingerprint them.
Currently, the turnt-tls client supports the following methods: GET
, POST
, FORM
, PUT
, and PUTFORM
.
Note: FORM is essentially a request with query parameters. We just decided this warranted a separate method.
var turnt = require("turnt-tls");
var jar = require("tough-cookie");
var cookieJar = new jar.CookieJar();
async function checkTLS() {
let options = {
method: 'GET',
cookieJar: cookieJar,
headers: {
'Connection': 'keep-alive',
'Pragma': 'no-cache',
'Cache-Control': 'no-cache',
'sec-ch-ua': '"Google Chrome";v="89", "Chromium";v="89", ";Not A Brand";v="99"',
'sec-ch-ua-mobile': '?0',
'DNT': '1',
'Upgrade-Insecure-Requests': '1',
'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36',
'Accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9',
'Sec-Fetch-Site': 'none',
'Sec-Fetch-Mode': 'navigate',
'Sec-Fetch-User': '?1',
'Sec-Fetch-Dest': 'document',
'Accept-Language': 'en-US,en;q=0.9'
},
proxy: "user:pass@host:port",
}
let GetResp = await turnt.turnt("https://incolumitas.com/pages/TLS-Fingerprint/", options)
console.log(GetResp.status)
}
checkTLS();
Much of the syntax is similar to the popular but deprecated requests package.
I have also taken the liberty to provide pre-made binaries that will run on MacOS, Linux, and Windows, however you are free to build your own. You can do so by running ./golang/build.bat
. (Windows only)
Anyone is welcome to contribute to this module to implement any more http methods or functionality. Just make a pull request and I will review it :)
I would like to give an enormous shoutout to Will for his contributions to this repository. Please go check out his work!