bypassed browser fingerprinting

This commit is contained in:
Quentin Roussel
2024-08-18 18:53:35 +08:00
parent abaf134c28
commit b189cd2351
6 changed files with 59 additions and 18 deletions

View File

@@ -20,20 +20,8 @@ function downloadImage(time_string, filepath) {
port: 443,
path: `/docs/default-source/rain-area/dpsri_70km_${time_string}0000dBR.dpsri.png`,
headers: {
"Host":"www.nea.gov.sg",
"User-Agent": "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:129.0) Gecko/20100101 Firefox/129.0",
"Accept": "image/avif,image/webp,image/png,image/svg+xml,image/*;q=0.8,*/*;q=0.5",
"Accept-Language": "en-US,en;q=0.5",
"Accept-Encoding": "gzip, deflate, br, zstd",
"DNT": "1",
"Connection": "keep-alive",
"Sec-Fetch-Dest": "image",
"Sec-Fetch-Mode": "no-cors",
"Sec-Fetch-Site": "same-origin",
"Priority": "i",
"Pragma": "no-cache",
"Cache-Control": "no-cache",
"TE": "trailers",
"User-Agent": "Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:129.0) Gecko/20100101 Firefox/129." + Math.round(Math.random() * 1000),
"Accept": "image/avif,image/webp,image/png,image/svg+xml,image/*;q=0.8,*/*;q=0.5;" + Math.round(Math.random() * 1000),
}
}
client.get(options, (res) => {