11/******
22* name: arkenfox user.js
3- * date: 12 June 2022
4- * version: 101
3+ * date: 1 July 2022
4+ * version: 102
55* url: https://github.com/arkenfox/user.js
66* license: MIT: https://github.com/arkenfox/user.js/blob/master/LICENSE.txt
77
@@ -82,7 +82,7 @@ user_pref("_user.js.parrot", "0100 syntax error: the parrot's dead!");
8282user_pref ( "browser.shell.checkDefaultBrowser" , false ) ;
8383/* 0102: set startup page [SETUP-CHROME]
8484 * 0=blank, 1=home, 2=last visited page, 3=resume previous session
85- * [NOTE] Session Restore is cleared with history (2811, 2812 ), and not used in Private Browsing mode
85+ * [NOTE] Session Restore is cleared with history (2811, 2820 ), and not used in Private Browsing mode
8686 * [SETTING] General>Startup>Restore previous session ***/
8787user_pref ( "browser.startup.page" , 0 ) ;
8888/* 0103: set HOME+NEWWINDOW page
@@ -389,11 +389,6 @@ user_pref("extensions.formautofill.heuristics.enabled", false); // [FF55+]
389389 [1] https://support.mozilla.org/kb/use-primary-password-protect-stored-logins-and-pas
390390***/
391391user_pref ( "_user.js.parrot" , "0900 syntax error: the parrot's expired!" ) ;
392- /* 0901: set when Firefox should prompt for the primary password
393- * 0=once per session (default), 1=every time it's needed, 2=after n minutes (0902) ***/
394- user_pref ( "security.ask_for_password" , 2 ) ;
395- /* 0902: set how long in minutes Firefox should remember the primary password (0901) ***/
396- user_pref ( "security.password_lifetime" , 5 ) ; // [DEFAULT: 30]
397392/* 0903: disable auto-filling username & password form fields
398393 * can leak in cross-site forms *and* be spoofed
399394 * [NOTE] Username & password is still available when you enter the field
@@ -522,7 +517,7 @@ user_pref("security.mixed_content.block_display_content", true);
522517 * [SETTING] to add site exceptions: Padlock>HTTPS-Only mode>On (after "Continue to HTTP Site")
523518 * [SETTING] Privacy & Security>HTTPS-Only Mode (and manage exceptions)
524519 * [TEST] http://example.com [upgrade]
525- * [TEST] http://neverssl .com/ [no upgrade] ***/
520+ * [TEST] http://httpforever .com/ [no upgrade] ***/
526521user_pref ( "dom.security.https_only_mode" , true ) ; // [FF76+]
527522 // user_pref("dom.security.https_only_mode_pbm", true); // [FF80+]
528523/* 1245: enable HTTPS-Only mode for local resources [FF77+] ***/
@@ -758,7 +753,7 @@ user_pref("_user.js.parrot", "2700 syntax error: the parrot's joined the bleedin
758753user_pref ( "browser.contentblocking.category" , "strict" ) ;
759754/* 2702: disable ETP web compat features [FF93+]
760755 * [SETUP-HARDEN] Includes skip lists, heuristics (SmartBlock) and automatic grants
761- * Opener Heuristics are granted for 30 days and Redirect Heuristics for 15 minutes , see [3]
756+ * Opener and redirect heuristics are granted for 30 days, see [3]
762757 * [1] https://blog.mozilla.org/security/2021/07/13/smartblock-v2/
763758 * [2] https://hg.mozilla.org/mozilla-central/rev/e5483fd469ab#l4.12
764759 * [3] https://developer.mozilla.org/en-US/docs/Web/Privacy/State_Partitioning#storage_access_heuristics ***/
@@ -768,26 +763,17 @@ user_pref("privacy.partition.serviceWorkers", true);
768763
769764/*** [SECTION 2800]: SHUTDOWN & SANITIZING ***/
770765user_pref ( "_user.js.parrot" , "2800 syntax error: the parrot's bleedin' demised!" ) ;
771- /** COOKIES + SITE DATA : ALLOWS EXCEPTIONS ***/
772- /* 2801: delete cookies and site data on exit
773- * 0=keep until they expire (default), 2=keep until you close Firefox
774- * [NOTE] A "cookie" block permission also controls localStorage/sessionStorage, indexedDB,
775- * sharedWorkers and serviceWorkers. serviceWorkers require an "Allow" permission
776- * [SETTING] Privacy & Security>Cookies and Site Data>Delete cookies and site data when Firefox is closed
777- * [SETTING] to add site exceptions: Ctrl+I>Permissions>Cookies>Allow
778- * [SETTING] to manage site exceptions: Options>Privacy & Security>Permissions>Settings ***/
779- user_pref ( "network.cookie.lifetimePolicy" , 2 ) ;
780- /* 2802: delete cache on exit [FF96+]
781- * [NOTE] We already disable disk cache (1001) and clear on exit (2811) which is more robust
782- * [1] https://bugzilla.mozilla.org/1671182 ***/
783- // user_pref("privacy.clearsitedata.cache.enabled", true);
784-
785- /** SANITIZE ON SHUTDOWN : ALL OR NOTHING ***/
766+ /** SANITIZE ON SHUTDOWN: ALLOWS COOKIES + SITE DATA EXCEPTIONS FF102+ ***/
786767/* 2810: enable Firefox to clear items on shutdown (2811)
787- * [SETTING] Privacy & Security>History>Custom Settings>Clear history when Firefox closes ***/
768+ * [NOTE] Exceptions: A "cookie" block permission also controls "offlineApps" (see note in 2811).
769+ * serviceWorkers require an "Allow" permission. For cross-domain logins, add exceptions for
770+ * both sites e.g. https://www.youtube.com (site) + https://accounts.google.com (single sign on)
771+ * [WARNING] Be selective with what cookies you keep, as they also disable partitioning (1767271)
772+ * [SETTING] Privacy & Security>History>Custom Settings>Clear history when Firefox closes
773+ * [SETTING] to add site exceptions: Ctrl+I>Permissions>Cookies>Allow (when on the website in question)
774+ * [SETTING] to manage site exceptions: Options>Privacy & Security>Permissions>Settings ***/
788775user_pref ( "privacy.sanitize.sanitizeOnShutdown" , true ) ;
789776/* 2811: set/enforce what items to clear on shutdown (if 2810 is true) [SETUP-CHROME]
790- * These items do not use exceptions, it is all or nothing (1681701)
791777 * [NOTE] If "history" is true, downloads will also be cleared
792778 * [NOTE] "sessions": Active Logins: refers to HTTP Basic Authentication [1], not logins via cookies
793779 * [NOTE] "offlineApps": Offline Website Data: localStorage, service worker cache, QuotaManager (IndexedDB, asm-cache)
@@ -798,10 +784,16 @@ user_pref("privacy.clearOnShutdown.downloads", true); // [DEFAULT: true]
798784user_pref ( "privacy.clearOnShutdown.formdata" , true ) ; // [DEFAULT: true]
799785user_pref ( "privacy.clearOnShutdown.history" , true ) ; // [DEFAULT: true]
800786user_pref ( "privacy.clearOnShutdown.sessions" , true ) ; // [DEFAULT: true]
801- user_pref ( "privacy.clearOnShutdown.offlineApps" , false ) ; // [DEFAULT: false]
802- user_pref ( "privacy.clearOnShutdown.cookies" , false ) ;
787+ user_pref ( "privacy.clearOnShutdown.offlineApps" , true ) ;
788+ user_pref ( "privacy.clearOnShutdown.cookies" , true ) ;
803789 // user_pref("privacy.clearOnShutdown.siteSettings", false); // [DEFAULT: false]
804- /* 2812: reset default items to clear with Ctrl-Shift-Del (to match 2811) [SETUP-CHROME]
790+ /* 2812: delete cache on exit [FF96+]
791+ * [NOTE] We already disable disk cache (1001) and clear on exit (2811) which is more robust
792+ * [1] https://bugzilla.mozilla.org/1671182 ***/
793+ // user_pref("privacy.clearsitedata.cache.enabled", true);
794+
795+ /** SANITIZE MANUAL: ALL OR NOTHING ***/
796+ /* 2820: reset default items to clear with Ctrl-Shift-Del [SETUP-CHROME]
805797 * This dialog can also be accessed from the menu History>Clear Recent History
806798 * Firefox remembers your last choices. This will reset them when you start Firefox
807799 * [NOTE] Regardless of what you set "downloads" to, as soon as the dialog
@@ -815,13 +807,13 @@ user_pref("privacy.cpd.cookies", false);
815807 // user_pref("privacy.cpd.downloads", true); // not used, see note above
816808 // user_pref("privacy.cpd.passwords", false); // [DEFAULT: false] not listed
817809 // user_pref("privacy.cpd.siteSettings", false); // [DEFAULT: false]
818- /* 2813 : clear Session Restore data when sanitizing on shutdown or manually [FF34+]
810+ /* 2821 : clear Session Restore data when sanitizing on shutdown or manually [FF34+]
819811 * [NOTE] Not needed if Session Restore is not used (0102) or it is already cleared with history (2811)
820812 * [NOTE] privacy.clearOnShutdown.openWindows prevents resuming from crashes (also see 5008)
821813 * [NOTE] privacy.cpd.openWindows has a bug that causes an additional window to open ***/
822814 // user_pref("privacy.clearOnShutdown.openWindows", true);
823815 // user_pref("privacy.cpd.openWindows", true);
824- /* 2814 : reset default "Time range to clear" for "Clear Recent History" (2812 )
816+ /* 2822 : reset default "Time range to clear" for "Clear Recent History" (2820 )
825817 * Firefox remembers your last choice. This will reset the value when you start Firefox
826818 * 0=everything, 1=last hour, 2=last two hours, 3=last four hours, 4=today
827819 * [NOTE] Values 5 (last 5 minutes) and 6 (last 24 hours) are not listed in the dropdown,
@@ -841,7 +833,6 @@ user_pref("privacy.sanitize.timeSpan", 0);
841833 FF53: fixes GetSupportedNames in nsMimeTypeArray and nsPluginArray (1324044)
842834 1330890 - spoof timezone as UTC0 (FF55)
843835 1360039 - spoof navigator.hardwareConcurrency as 2 (FF55)
844- 1217238 - reduce precision of time exposed by javascript (FF55)
845836 FF56
846837 1369303 - spoof/disable performance API
847838 1333651 - spoof User Agent & Navigator API
@@ -883,6 +874,7 @@ user_pref("privacy.sanitize.timeSpan", 0);
883874 FF91+
884875 531915 - use fdlibm's sin, cos and tan in jsmath (FF93, ESR91.1)
885876 1756280 - enforce navigator.pdfViewerEnabled as true and plugins/mimeTypes as hard-coded values (FF100)
877+ 1692609 - reduce JS timing precision to 16.67ms (previously FF55+ was capped at 100ms) (FF102)
886878***/
887879user_pref ( "_user.js.parrot" , "4500 syntax error: the parrot's popped 'is clogs" ) ;
888880/* 4501: enable privacy.resistFingerprinting [FF41+]
@@ -975,7 +967,7 @@ user_pref("_user.js.parrot", "5000 syntax error: the parrot's taken 'is last bow
975967/* 5005: disable intermediate certificate caching [FF41+] [RESTART]
976968 * [NOTE] This affects login/cert/key dbs. The effect is all credentials are session-only.
977969 * Saved logins and passwords are not available. Reset the pref and restart to return them ***/
978- // user_pref("security.nocertdb", true); // [HIDDEN PREF]
970+ // user_pref("security.nocertdb", true); // [HIDDEN PREF in FF101 or lower ]
979971/* 5006: disable favicons in history and bookmarks
980972 * [NOTE] Stored as data blobs in favicons.sqlite, these don't reveal anything that your
981973 * actual history (and bookmarks) already do. Your history is more detailed, so
@@ -1068,8 +1060,6 @@ user_pref("network.http.referer.spoofSource", false); // [DEFAULT: false]
10681060/* 6004: enforce a security delay on some confirmation dialogs such as install, open/save
10691061 * [1] https://www.squarefree.com/2004/07/01/race-conditions-in-security-dialogs/ ***/
10701062user_pref ( "security.dialog_enable_delay" , 1000 ) ; // [DEFAULT: 1000]
1071- /* 6007: enforce Local Storage Next Generation (LSNG) [FF65+] ***/
1072- user_pref ( "dom.storage.next_gen" , true ) ; // [DEFAULT: true FF92+]
10731063/* 6008: enforce no First Party Isolation [FF51+]
10741064 * [WARNING] Replaced with network partitioning (FF85+) and TCP (2701),
10751065 * and enabling FPI disables those. FPI is no longer maintained ***/
@@ -1142,7 +1132,7 @@ user_pref("_user.js.parrot", "7000 syntax error: the parrot's pushing up daisies
11421132/* 7005: disable SSL session IDs [FF36+]
11431133 * [WHY] Passive fingerprinting and perf costs. These are session-only
11441134 * and isolated with network partitioning (FF85+) and/or containers ***/
1145- // user_pref("security.ssl.disable_session_identifiers", true); // [HIDDEN PREF]
1135+ // user_pref("security.ssl.disable_session_identifiers", true); // [HIDDEN PREF in FF101 or lower ]
11461136/* 7006: onions
11471137 * [WHY] Firefox doesn't support hidden services. Use Tor Browser ***/
11481138 // user_pref("dom.securecontext.allowlist_onions", true); // [FF97+] 1382359/1744006
@@ -1342,6 +1332,22 @@ user_pref("security.csp.enable", true); // [DEFAULT: true]
13421332 // user_pref("network.http.spdy.enabled.deps", false);
13431333 // user_pref("network.http.spdy.enabled.http2", false);
13441334 // user_pref("network.http.spdy.websockets", false); // [FF65+]
1335+ // FF102
1336+ // 0901: set when Firefox should prompt for the primary password
1337+ // 0=once per session (default), 1=every time it's needed, 2=after n minutes (0902)
1338+ // [-] https://bugzilla.mozilla.org/1767099
1339+ user_pref("security.ask_for_password", 2);
1340+ // 0902: set how long in minutes Firefox should remember the primary password (0901)
1341+ // [-] https://bugzilla.mozilla.org/1767099
1342+ user_pref("security.password_lifetime", 5); // [DEFAULT: 30]
1343+ // 2801: delete cookies and site data on exit - replaced by sanitizeOnShutdown* (2810)
1344+ // 0=keep until they expire (default), 2=keep until you close Firefox
1345+ // [SETTING] Privacy & Security>Cookies and Site Data>Delete cookies and site data when Firefox is closed
1346+ // [-] https://bugzilla.mozilla.org/buglist.cgi?bug_id=1681493,1681495,1681498,1759665
1347+ user_pref("network.cookie.lifetimePolicy", 2);
1348+ // 6007: enforce Local Storage Next Generation (LSNG) [FF65+]
1349+ // [-] https://bugzilla.mozilla.org/1764696
1350+ user_pref("dom.storage.next_gen", true); // [DEFAULT: true FF92+]
13451351// ***/
13461352
13471353/* END: internal custom pref to test for syntax errors ***/
0 commit comments