跪拜 Guibai
← All articles
Python · Linux · Artificial Intelligence

The Incognito Placebo: 30 Lines of JS Extract a Hardware Fingerprint That Survives Private Windows and Proxy IPs

By 第404号工位 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Device fingerprinting turns incognito mode into a false sense of security: trackers can tie a private session to a known user simply by matching stable hardware traits. For developers building anti-fraud or privacy tools, the practical consequence is that local data clearing alone never works, and only browser-level fingerprint standardization or full VM isolation offers real protection.

Summary

Incognito mode only segments the local browser session: it stops writing history and resets cookies in memory, but every HTTP request still carries a set of hardware-derived identifiers. The article's 30-line probe combines Canvas 2D rendering, WebGL debug info, an OfflineAudioContext fingerprint, CPU core count, deviceMemory, screen resolution, and timezone. In tests, a normal Chrome window and a fresh incognito window produced byte-identical values, including a canvas hash of 0x244f4e0d and an Apple M4 GPU string.

The reason is that these traits come from the physical rendering stack: font rasterization, GPU shaders, and audio processing happen locally and change only with hardware and OS, not with private mode. EFF's Panopticlick model estimates 33-36 bits of entropy from combined traits, enough to make a device unique among 8.5 billion people. Switching to a proxy IP changes the network source but not the fingerprint, and WebRTC can bypass the proxy to leak the real IP over UDP.

Takeaways
— Incognito mode only removes local session data (cookies, history) from the device; it does not alter data sent to servers.
— The demo's 30-line JavaScript uses Canvas 2D, WebGL debug info, OfflineAudioContext, and navigator properties to generate a stable fingerprint.
— Test results from normal and incognito windows produced identical values: canvasHash 0x244f4e0d, Apple M4 GPU, audioFingerprint 124.04347480, 10 cores, 16GB RAM, 1512x982x24 screen, Asia/Shanghai timezone.
— EFF's Panopticlick model estimates 33-36 bits of entropy from combined fingerprint traits, enough to uniquely identify a device among 8.5 billion people.
— Swapping your IP via proxy does not change the hardware fingerprint; a server can still match the fingerprint to a known user profile.
— WebRTC uses UDP and can bypass proxies, leaking your real public and private IP addresses via STUN servers.
— Canvas random-noise plugins create an even more unique anomaly, making you stand out as a high-risk bot.
— Effective defenses include Safari's Advanced Tracking and Fingerprint Protection, Brave's Farbling (per-site fixed random seeds), Firefox's privacy.resistFingerprinting, disabling WebRTC (media.peerconnection.enabled false), and running in a disposable VM.
Conclusions

Randomizing Canvas output with a plugin backfires because the anomaly itself becomes the rarest fingerprint, as the article's 'fingerprint paradox' demonstrates.

The WebRTC leak is a reminder that proxies only protect TCP/HTTP unless they intercept UDP at the network layer; this is why TUN mode is mandatory for real anonymity.

The defense tiers show that true anonymity requires either blending into a standardized group (Tor, Brave, Safari) or physically isolating the environment (VM), not tweaking settings in a regular browser.

Concepts & terms
Device Fingerprinting
A technique that builds a unique identifier for a device by combining hardware and software traits such as GPU model, screen resolution, audio processing quirks, and fonts. Unlike cookies, these traits are stable and not cleared by private mode.
Canvas Fingerprinting
An image drawn by the browser's 2D canvas is hashed; subtle differences in font rasterization, anti-aliasing, and GPU shader rounding produce a unique hash for each device.
WebRTC STUN Leak
WebRTC's UDP-based candidates can bypass proxy settings and reveal a user's real public and private IP addresses through STUN servers, even when a proxy is active.
Fingerprint Paradox
The more you try to randomize or obscure your fingerprint, the more you stand out, because normal users share similar clusters and any unusual inconsistency becomes an identifying marker.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗