BrowserShield: Antifingerprinting script for Firefox
BrowserShield is a simple javascript userscript for Firefox and Firefox-based browsers that helps you to prevent websites from fingerprinting your browser. Protect yourself against surveillance!
This extension was tested using Mozilla Firefox and Palemoon, so I don't know if it will work in other browsers!
This userscript doesn't spoof HTTP headers, for now. Just spoofs javascript variables, so please install an "user agent switcher" if you want to spoof HTTP headers.
Installation
"Quick" installation
- Install any Firefox extension for userscripts support (Ace Script (highly recommended), greasemonkey (may block the spoofing in Mozilla Firefox), etc.)
- Click this button → [Install BrowserShield]
- Now the script is installed, but it won't work yet! It's necessary to modify some browser preferences.
- Type "about:config" in the Firefox address bar.
- A warning screen would be shown, don't worry, Firefox does this to prevent you from breaking your browser, but we're just going to disable some "content security policies" that prevent you from executing some userscripts, so click "I accept the risk!" to continue.
- Search for the following preferences in the search bar:
extensions.webextensions.base-content-security-policy
and extensions.webextensions.default-content-security-policy
- Replace them all with an empty string/text (yeah, they must be blank).
- Now search for the
security.csp.enable
preference.
- Its value is set to "true" by default, so set it to "false" (double-click).
- Now you are protected from fingerprinting! Visit http://mybrowserinfo.com/ (or any other web browser info website) and you'll see your device info is now spoofed.
Manual installation
If the method listed above didn't work, follow these steps:
- Install any Firefox extension for userscripts support (Ace Script (highly recommended), greasemonkey (may block the spoofing in Mozilla Firefox), etc.)
- Go to your userscript extension dashboard.
- Install BrowserShield userscript from this URL
https://notabug.org/nokoru/browser-shield/raw/master/browser-shield.user.js
- Now the script is installed, but it won't work yet! It's necessary to modify some browser preferences.
- Type "about:config" in the Firefox address bar.
- A warning screen would be shown, don't worry, Firefox does this to prevent you from breaking your browser, but we're just going to disable some "content security policies" that prevent you from executing some userscripts, so click "I accept the risk!" to continue.
- Search for the following preferences in the search bar:
extensions.webextensions.base-content-security-policy
and extensions.webextensions.default-content-security-policy
- Replace them all with an empty string/text (yeah, they must be blank).
- Now search for the
security.csp.enable
preference.
- Its value is set to "true" by default, so set it to "false" (double-click).
- Now you are protected from fingerprinting! Visit http://mybrowserinfo.com/ (or any other web browser info website) and you'll see your device info is now spoofed.
How BrowserShield works
This userscript spoofs some of your browser's javascript "read-only" properties that most of fingerprinting websites use to uniquely identify your computer, this is particularly dangerous if you're using a non-popular browser or OS, so BrowserShield makes your computer appear to be "more common" (example of spoofing: fake your OS to Windows 10, which is a very popular operating system).
Credits
BrowserShield was originally written by me (nokoru). BrowserShield is just a little project I started as a hobby to support online privacy, and learn some git.
Contact me