Compare commits

...

126 Commits

Author SHA1 Message Date
e5d23f6b40 60-beta 2018-05-15 20:40:12 +00:00
5fc48a1027 Create ghacks-clear-FF60inclusive-[RFP-alternatives].js 2018-05-16 07:29:33 +12:00
de7a8650f7 Create ghacks-clear-FF60inclusive-[removed].js 2018-05-16 07:29:11 +12:00
9c7170fc26 Create ghacks-clear-FF60inclusive-[deprecated].js 2018-05-16 07:28:32 +12:00
9406f32194 Delete ghacks-clear-all-up-to-57-[the-rest-inactive].js 2018-05-15 17:43:01 +00:00
33759ab604 Delete ghacks-clear-all-up-to-57-[the-rest-active].js 2018-05-15 17:42:46 +00:00
f97c9a05a9 Delete ghacks-clear-all-up-to-57-[removed].js 2018-05-15 17:42:30 +00:00
94abd71787 Delete ghacks-clear-all-up-to-57-[deprecated].js 2018-05-15 17:42:13 +00:00
45f1dfa912 Delete ghacks-clear-57-[changes-only].js 2018-05-15 17:42:00 +00:00
d6280d2d7a Delete ghacks-clear-all-up-to-57-[RFP-alternatives].js 2018-05-15 17:41:43 +00:00
67360332ab FF60+ parrot info 2018-05-15 15:44:37 +00:00
b880c9da61 add network.ftp.enabled 2018-05-11 18:14:40 +02:00
1b0c9f66d9 2600s renumber/reorder #368 2018-05-08 04:13:53 +12:00
7eda26a1d0 2600s numbering part1 2018-05-07 15:51:50 +00:00
b89e247263 0707: DoH, fixes #410 2018-05-07 14:57:42 +00:00
35fd4e343c 2671 cleanup #368 2018-05-06 20:41:14 +00:00
47cf0e1640 2617 pdfjs tweak #368
that trims 3 lines off with a little formatting
2018-05-06 18:41:10 +00:00
5e7258ba2d remove 0705, fixes #418 2018-05-06 17:07:09 +00:00
6e6a993494 2672 punycode tweak #368 2018-05-06 16:57:00 +00:00
772fa4e06e geo changes, fixes #415
NOTE: RFP still blocks geo, but this will be reverted at some stage: see https://bugzilla.mozilla.org/show_bug.cgi?id=1441295
2018-05-06 13:10:30 +00:00
78dc31f6d6 remove 5 prefs #418 2018-05-06 12:30:40 +00:00
459396ed5b 2626: remove useragent.compatMode #368
I see no point in keeping this to enforce a default that FF itself doesn't use - see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent/Firefox
-  "... is an optional compatibility token that some Gecko-based browsers may choose to incorporate, to achieve maximum compatibility with websites that expect Firefox"
2018-05-06 10:00:13 +00:00
88b08c79cd 2685 tweak 2018-05-05 18:44:52 +00:00
cf269c982b fixup number ref 2018-05-05 18:26:33 +00:00
36c11cb5d4 2600: downloads + extensions regroup (#417)
* 2600: downloads + extensions regroup

* fixup
2018-05-06 06:14:57 +12:00
517b8665c0 2685 fixup 2018-05-05 17:01:09 +00:00
149aab6b1e 2600: security regroup (#416)
* 2600: security regroup

* fixup
2018-05-06 04:21:21 +12:00
c5a1a038d2 5000: remove view_source.tab (moved to 9999) 2018-05-05 14:40:20 +02:00
cd322f39a4 2613: restrictedDomains 2018-05-04 21:55:51 +00:00
8f2b674910 60 deprecated/removed part2 2018-05-04 21:42:47 +00:00
7d65d8c173 4503 mozAddonManager => active 2018-05-04 21:18:45 +00:00
8b6eec2b46 RFP ESR version spoof info
The last one-off ESR cycle of 8 releases is now behind us, new algorithm for FF60+ is back to 7 releases per ESR numbering, starting at 60... 67... etc. Note: This does not do anything for Aurora or Nightly spoofing the next ESR early (but we have until Nightly 67 before this becomes a problem). The ticket 1418162 was meant to cover this but instead was just used for the new algorithm. There is currently no ticket for the Aurora/Nightly issue - but never fear, Pants is here!! It is not forgotten, and I have emails with Tom Ritter et al on it
2018-05-04 18:30:44 +00:00
13164a2d0d 4500s: RFP disable WebGL debug renderer info (60+) 2018-05-04 17:23:26 +00:00
c4a1583e99 60 RFP Alternatives 2018-05-04 17:11:34 +00:00
d10c8598f7 60 deprecated/removed prefs 2018-05-04 16:56:14 +00:00
40db113d07 2706: same-site cookies 2018-05-04 16:08:20 +00:00
041e14a4d5 ghacks-user.js updater for Mac/Linux v1.3 (#406)
* updated shebang

* The script now compares its version number to the one online.  If there is a newer version of `updater.sh` online it ask the user if he wants to download and run it.
   * 2 parameters are supported: `-donotupdate` to disable the update-check and `-update` to auto-download and run the new version without asking

* Backup files are now saved to the directory `userjs_backups` instead of causing more bloat in the profile directory.
2018-05-03 14:49:43 +02:00
e67fdc2ce4 5000s: ui.key.menuAccessKey 2018-04-29 19:21:58 +00:00
75534b4e6c 0515: uploading to Screenshots server 2018-04-29 13:42:02 +00:00
94c0665343 fix wiki test info on SB 2018-04-28 07:30:47 +00:00
71adc43d17 v1.1 regex fix (#409) 2018-04-25 22:56:54 +02:00
94f86465e6 updater for Windows v4.5 (#407)
support commenting-out active user-prefs with the merge function
2018-04-25 21:28:09 +02:00
bb4bf835b0 v2.1 - fix TABs in regex
for some unknown reason the tabs got replaced with spaces
2018-04-25 02:22:14 +02:00
b4f1b4dbbf prefsCleaner.sh (for Linux/Mac) (#405)
Port of the prefsCleaner.bat for anything(?) with a bash shell.
2018-04-24 14:47:50 +02:00
f90c17f748 prefsCleaner 2.0
- massive speed improvement !! m-a-s-s-i-v-e !
- small fix to the time format used in backup filenames (replace space with zeros)
- better tolerance for special characters within preference names (which counters [the one downside that v1.2 brought along](https://github.com/ghacksuserjs/ghacks-user.js/pull/321#issuecomment-354394222)).
- other minor things, mostly to do with Delayed Expansion and the removal of it

known issue (but not really an issue):
- it skips instances of `user_pref` that have any quote or double-quote before `user_pref` (like `// "this" user_pref`)
2018-04-22 14:16:05 +02:00
fdac8fba6a Update prefsCleaner.bat 2018-04-22 01:34:48 +00:00
d055560f6f 0514: tweak 2018-04-21 17:26:12 +00:00
27f87240ec 0514: Activity Stream, fixes #396
AS is out of control. No master switch in FF60+, and in order to 100% sure nothing is collected locally (or external connections made), there are now some 28 prefs (including those coming in FF61). This is re-DICK-ulous. We're not going to bother tracking all that, let alone the labyrinth of code. All users are advised to just make sure they remove the XPI every time they update FF.
2018-04-21 16:33:35 +00:00
17d83c1a1a 1600 info: fixes #404 , refixes #332 2018-04-21 16:22:04 +00:00
8fa3a9db6b fix for missing empty lines 2018-04-21 14:34:08 +00:00
b0fb59f735 shit is so fast I can't even read 2018-04-18 22:42:06 +00:00
64d08dd6bc Update updater.bat 2018-04-18 20:33:39 +00:00
824dec4f9e Update prefsCleaner.bat 2018-04-18 20:29:39 +00:00
3d2b0703be actually working v2 2018-04-18 18:49:36 +00:00
e25137ce94 v2
Mostly a bump in performance.
2018-04-18 16:18:43 +00:00
6ee25c2bf5 change last commit to number 0380
note to self: listen to earthlng more
2018-04-13 17:27:45 +00:00
6309822d33 0352: browser error reporter 2018-04-13 17:19:31 +00:00
d04ff8457e 2730b: disable appCache on insecure sites FF60+ 2018-04-12 17:38:22 +00:00
c6e3c013e0 4500: RFP info on plugins/mimetypes 2018-04-10 17:25:23 +00:00
e373a0f6e1 1273: add "Not Secure" text on HTTP
https://bugzilla.mozilla.org/show_bug.cgi?id=1335970
2018-04-05 18:57:08 +00:00
acce871308 2701: cookies role in persistent data, fixes #390 2018-04-04 10:42:52 +00:00
61e706641e 2800 section header info 2018-04-04 10:21:40 +00:00
1e5e2ca418 start 60 commits 2018-04-04 10:18:23 +00:00
c62bff5c70 end of v59 2018-04-04 10:14:15 +00:00
3bae3ed5ba move 2711 to 2600s
2711 is about web extension data and does not fit in the 2700s is all about websites' persistent data, i.e items that sanitizing and Storage Manager deal with. Dumping in 2600's which is getting a revamp later
2018-03-30 16:20:56 +00:00
aa91ea1680 4000: FPI indexedDB info 2018-03-27 23:03:53 +00:00
d244198438 RFP: CTRL key fix backported to 59.0.2 2018-03-27 17:03:36 +00:00
871e7ed87b minor edits, settings info 2018-03-27 10:08:20 +13:00
48901d156a 2621: add [SETTING-ESR] 2018-03-26 21:03:53 +00:00
8b4e6c95aa xpinstall.whitelist.required, fixes #375 2018-03-26 20:23:06 +00:00
fd1aa74ff3 Options> and [settings] (#388)
* Options> and [settings]

While I'm at it, I'm changing the 21 instances of
- `[SETTING-56+]` to just `[SETTING]`
- `[SETTING-ESR]` to `[SETTING-ESR52]` because we'll leave those in until 62 (yes I know they may apply to earlier ESRs, but people should be upgraded). Thus no ambiguity with ESR60 vs ESR52 users for the overlap
2018-03-27 08:49:39 +13:00
b3e92ab7cc fixup // default syntax 2018-03-26 19:44:15 +00:00
30fbaba4df 2203: undo sh*t
This is so wrong: It is better to inform users that 3 **must** be used than rely on zero info as well as removing useful info on what the values do. All future issues with this will be directed to earthlng. Remove RFP info as RFP users should know this stuff if they turned it on. Non RFP users, who we told they can bypass it, will not have a reference to RFP now. Enforce will now be banned as a word because, "reasons".
2018-03-26 19:33:46 +00:00
72e1858926 how did this get left behind 2018-03-26 17:13:46 +00:00
3ad6ed465e 2200s: more tweaks 2018-03-27 06:04:31 +13:00
3fcad90996 2200s: tweaks 2018-03-27 05:01:30 +13:00
383b8ca943 revamp 2400s: fixes #371 2018-03-26 20:34:02 +13:00
6a98aa7ba0 2750+2730: enable appcache + storage #379 2018-03-25 12:59:49 +00:00
2037449fbd 2750: rethinking it #379
add `browser.storageManager.enabled` back but enforce it as true - otherwise people may never pick up on the fact we dropped it and may never reset it, and never see their shiny new UI section. When it's deprecated, *then* we can remove it
2018-03-25 10:56:49 +00:00
e18bd0f32c 2750: stop hiding Storage Manager UI #379
pref will be removed, 99% sure it was just a pref used internally to hide it from stable during testing in beta/nightly - see https://bugzilla.mozilla.org/show_bug.cgi?id=1428306. Makes zero sense to hide this new UI section since we will be turning SM on anyway (the section is important for end users to exist and be working esp thru QuotaManager and Storage v2 changes etc).
2018-03-25 10:50:52 +00:00
715fff06cf clean up 2202+2203 #371 2018-03-25 10:07:27 +00:00
3675a68009 2201+2205=>2400's #371
new numbers 2401 and 2404 do not exist anymore in the user.js so safe to use
2018-03-25 09:53:52 +00:00
062dd6c023 0500s: System Add-ons not system extensions
they're still called System Add-ons: https://firefox-source-docs.mozilla.org/toolkit/mozapps/extensions/addon-manager/SystemAddons.html
Thanks!
2018-03-21 04:53:53 +13:00
bc17b4e450 0500s: shield->normandy info, fixes #381 2018-03-20 15:29:37 +00:00
682e12fe57 4500: RFP ctrl key info
Sorry, the patch for 59 was backed out, so RFP users will have to put up with CTRL key issues until 60 lands
2018-03-20 12:54:10 +00:00
6cb27ca78c 0351: [setting] info 2018-03-20 05:47:04 +00:00
c38ae56232 0333: [setting] info 2018-03-20 05:42:05 +00:00
04f1449003 0512: shield pref name changes 60+
https://bugzilla.mozilla.org/show_bug.cgi?id=1436113
2018-03-20 03:57:18 +00:00
53a69ff5bc [SETTING] fixups 2018-03-19 14:13:00 +00:00
e8c02278eb 2676: forgot FF version 2018-03-17 06:36:08 +00:00
457611f079 59-alpha release 2018-03-17 05:06:15 +00:00
09aca71822 2676 fixup 2018-03-17 05:32:40 +01:00
f90193ab76 1600s: vimeo reference fixes #373 2018-03-17 02:56:36 +00:00
ffced9b4c0 2676: disable CSP security violation events 2018-03-17 02:27:39 +00:00
0b3395b520 2516: disable PointerEvents 2018-03-17 01:53:23 +00:00
d4a20165ef 0330: telemetry fixup 2018-03-14 15:08:33 +00:00
089f0826cf 0330: more telemetry 2018-03-14 15:00:13 +00:00
b83d53e681 bugzilla ref changes fixups #375 2018-03-14 14:03:04 +00:00
14456b5a29 bugzilla ref changes #375
note: picked up a leading space on 2206. Please double check for any errors or missed opportunities (I scanned it three times), 1221 is about the only one that's a bit messy I think
2018-03-15 02:22:58 +13:00
517e40703f reference: http->https 2018-03-14 11:19:09 +00:00
7f7282a975 59 deprecated tweaks 2018-03-14 11:05:37 +00:00
6fd415eab2 59 RFP Alternatives 2018-03-13 19:26:39 +00:00
d4083e6a3e 59 deprecated/removed prefs [part 2]
Note: I moved the (part`x`) bit to the end of the bugzilla from previous commit as I like the https* bit to all be in line = visually easier to parse IMO
2018-03-13 18:56:22 +00:00
3192027f52 59 deprecated/removed prefs [part 1] 2018-03-14 05:52:14 +13:00
2a402310cc fixup: missing line break 2018-03-13 09:23:17 +00:00
1469e13df8 section 0700 #368
This is a start to reducing section 2600 (which I renamed it to just miscellaneous). We can always revisit this new section and add to it down the track if required. Note: added a second ref [2] under 0703. Note: re-numbered & re-positioned deprecated prefs for SPDY
2018-03-13 09:04:54 +00:00
92585ecd93 browser.link.open_newwindow #371
adding this back in (so it is not missing for release changes), section will get a makeover, see linked issue
2018-03-13 08:00:20 +00:00
205d64ab29 4500: RFP keyboard ctrl key 2018-03-08 00:54:47 +00:00
3812aed9e9 Update troubleshooter.js 2018-03-05 14:19:34 +01:00
a83f5a0f5f Merge pull request #370 from claustromaniac/patch-2
Update updater.bat
2018-03-02 12:19:43 +01:00
19c40eeb18 fixup 2018-03-02 05:10:11 +00:00
61d2b46a02 5000: identity.fxaccounts.enabled, fixes #366 2018-03-02 05:09:29 +00:00
b93c7e026c revamp 5000 fixes #360 2018-03-02 16:53:39 +13:00
ec687cad75 remove 5020 #360
"remove 5020 because the values we set are the default values in Mac + Windows. Linux sets it the other way around: false+true instead of true+false"
2018-03-02 03:13:39 +00:00
6b691ae7e3 remove 5016 #360
covered by 5015 and only designed as a temporary pref AFAIK until issues with its timing and use (too distracting) are sorted
2018-03-02 02:39:45 +00:00
40da3653d3 remove 5007 #360
the default value is 3 anyway, and there it has a UI checkbox setting - don't ask me why a checkbox which only allows two values (2 or 3)
2018-03-01 21:12:40 +00:00
77a5894fa0 remove 5021* #360
These are all at default values, no need to enforce. As for removing them, we're de-cluttering the section and these just aren't that important. Anyone who wants to play with tab ordering/focus/etc could probably use an extension (API's?) and/or easily find these and look them up
2018-03-01 20:57:45 +00:00
11bcf46063 Update updater.bat 2018-03-01 19:15:10 +00:00
2dd2f5febe 0409: it is now 0201: see previous commit
whoops .. missed removing this part: overworked, underpaid, poor pants needs a beer
2018-03-01 12:48:31 +00:00
2de13258ff 4609 + 4612: move back to 0200s
geolocation blocking via RFP will be removed (see https://bugzilla.mozilla.org/show_bug.cgi?id=1441295), and since either way you look at it (those who use RFP or not) the user.js blocks geo, so we might as well move this stuff back to section 0200
2018-03-01 12:26:10 +00:00
40391a26a2 2629 - link added
link [1] is the ticket where the pref was initially added in FF42 with default `false`. The new link details the changes to the pref since then.
2018-03-01 12:12:24 +01:00
50186412e4 2621 - default info added
default is true in all current versions (ESR, Release, Beta, Nightly) and OSes
2018-03-01 12:09:09 +01:00
9892c3cbb7 4500: RFP canvas
1376865 was back ported to 59, so canvas prompt fatigue will be reduced. Note: the default for non-prompts is the same as if you clicked "Don't Allow" - i.e it serves up a 10x10px white square
2018-03-01 04:32:12 +00:00
887e93a4f2 4500: RFP WebGL stuff 2018-02-28 12:19:36 +00:00
7f1a82365c 4500: RFP UA spoof stuff
Cleaning up the UA spoof stuff in the sticky, as a ticket was just closed (52 is now a temporary hard-coded value: 1418672 - I guess they're running out of time), so also cleaning up the info, and consistent layout

Two issues: The code to determine the ESR number is out of whack (by one) since the next ESR is 60. 59 stable is almost here. So they have decided to hard-code the value as 52, for now. The second issue is that Aurora/Nightly are ahead of stable/ESR and can thus unmask themselves as Aurora/Nightly. The hard-coded value for now also solves this.

If you follow the sticky for RFP, you will see there is a ticket for using the update channel information (eg stable, beta, dev, nightly etc) to determine when and how calculate the version spoof in future, and they'll also rejig the numbering algorithm to account for ESR being out by one. These are tickets https://bugzilla.mozilla.org/show_bug.cgi?id=1418162 and https://bugzilla.mozilla.org/show_bug.cgi?id=1428111
2018-02-28 12:10:05 +00:00
8996071cd0 start 59 commits 2018-02-27 13:56:08 +00:00
13 changed files with 959 additions and 1364 deletions

View File

@ -1,18 +1,17 @@
@ECHO OFF
@ECHO OFF & SETLOCAL DisableDelayedExpansion
TITLE prefs.js cleaner
REM ### prefs.js cleaner for Windows
REM ## author: @claustromaniac
REM ## version: 1.2
REM ## version: 2.1
SETLOCAL EnableDelayedExpansion
:begin
ECHO:
ECHO:
ECHO ########################################
ECHO #### prefs.js cleaner for Windows ####
ECHO #### by claustromaniac ####
ECHO #### v1.2 ####
ECHO #### v2.1 ####
ECHO ########################################
ECHO:
CALL :message "This script should be run from your Firefox profile directory."
@ -29,12 +28,13 @@ IF NOT EXIST "user.js" (CALL :abort "user.js not found in the current directory.
IF NOT EXIST "prefs.js" (CALL :abort "prefs.js not found in the current directory." 30)
CALL :FFcheck
CALL :message "Backing up prefs.js..."
COPY /B /V /Y prefs.js "prefs-backup-!date:/=-!_!time::=.!.js"
SET "_time=%time: =0%"
COPY /B /V /Y prefs.js "prefs-backup-%date:/=-%_%_time::=.%.js"
CALL :message "Cleaning prefs.js..."
CALL :cleanup
CLS
CALL :message "All done^!"
CALL :message "All done!"
TIMEOUT 5 >nul
ENDLOCAL
EXIT /B
REM ########## Abort Function ###########
@ -44,11 +44,9 @@ TIMEOUT %~2 >nul
EXIT
REM ########## Message Function #########
:message
SETLOCAL DisableDelayedExpansion
ECHO:
ECHO: %~1
ECHO:
ENDLOCAL
GOTO :EOF
REM ####### Firefox Check Function ######
:FFcheck
@ -57,7 +55,7 @@ IF NOT ERRORLEVEL 1 (
CLS
CALL :message "Firefox is still running."
ECHO If you're not currently using this profile you can continue, otherwise
CALL :message "close Firefox first^!"
CALL :message "close Firefox first!"
ECHO:
PAUSE
CLS
@ -67,23 +65,20 @@ IF NOT ERRORLEVEL 1 (
GOTO :EOF
REM ######### Cleanup Function ##########
:cleanup
SETLOCAL DisableDelayedExpansion
FOR /F tokens^=2^ delims^=^'^" %%G IN ('FINDSTR /R /C:"^[^\"']*user_pref[ ]*\([ ]*[\"'][^\"']*[\"'][ ]*," user.js') DO (
IF NOT ""=="%%G" (SET "[%%G]=1")
)
(
FOR /F "tokens=1,* delims=:" %%G IN ('FINDSTR /N "^" prefs.js') DO (
SET "_line=%%H"
SETLOCAL EnableDelayedExpansion
IF /I "user_pref"=="!_line:~0,9!" (
FOR /F tokens^=2^ delims^=^" %%I IN ("!_line:.=\.!") DO (
FINDSTR /R /C:"user_pref[ ]*\([ ]*[\"']%%I[\"'][ ]*," user.js >nul
IF ERRORLEVEL 1 (ECHO:!_line!)
)
IF ""=="%%H" (
ECHO:
) ELSE (
ECHO:!_line!
FOR /F tokens^=1^,2^ delims^=^"^' %%I IN ("%%H") DO (
IF NOT DEFINED [%%J] (ECHO:%%H)
)
)
ENDLOCAL
)
)>tempcleanedprefs
ENDLOCAL
MOVE /Y tempcleanedprefs prefs.js
GOTO :EOF
REM ############### Help ##################

99
prefsCleaner.sh Normal file
View File

@ -0,0 +1,99 @@
#!/usr/bin/env bash
## prefs.js cleaner for Linux/Mac
## author: @claustromaniac
## version: 1.1
## special thanks to @overdodactyl and @earthlng for a few snippets that I stol..*cough* borrowed from the updater.sh
currdir=$(pwd)
## get the full path of this script (readlink for Linux, greadlink for Mac with coreutils installed)
sfp=$(readlink -f "${BASH_SOURCE[0]}" 2>/dev/null || greadlink -f "${BASH_SOURCE[0]}" 2>/dev/null)
## fallback for Macs without coreutils
if [ -z "$sfp" ]; then sfp=${BASH_SOURCE[0]}; fi
## change directory to the Firefox profile directory
cd "$(dirname "${sfp}")"
fQuit() {
## change directory back to the original working directory
cd "${currdir}"
echo -e "\n$2"
exit $1
}
fFF_check() {
# there are many ways to see if firefox is running or not, some more reliable than others
# this isn't elegant and might not be future-proof but should at least be compatible with any environment
while [ -e webappsstore.sqlite-shm ]; do
echo -e "\nThis Firefox profile seems to be in use. Close Firefox and try again.\n"
read -p "Press any key to continue."
done
}
fClean() {
# the magic happens here
prefs="@@"
prefexp="user_pref[ ]*\([ ]*[\"']([^\"']+)[\"'][ ]*,"
while read -r line; do
if [[ "$line" =~ $prefexp && $prefs != *"@@${BASH_REMATCH[1]}@@"* ]]; then
prefs="${prefs}${BASH_REMATCH[1]}@@"
fi
done <<< "`grep -E \"$prefexp\" user.js`"
while IFS='' read -r line || [[ -n "$line" ]]; do
if [[ "$line" =~ ^$prefexp ]]; then
if [[ $prefs != *"@@${BASH_REMATCH[1]}@@"* ]]; then
echo "$line"
fi
else
echo "$line"
fi
done < "$1" > prefs.js
}
echo -e "\n\n"
echo " ╔══════════════════════════╗"
echo " ║ prefs.js cleaner ║"
echo " ║ by claustromaniac ║"
echo " ║ v1.1 ║"
echo " ╚══════════════════════════╝"
echo -e "\nThis script should be run from your Firefox profile directory.\n"
echo "It will remove any entries from prefs.js that also exist in user.js."
echo "This will allow inactive preferences to be reset to their default values."
echo -e "\nThis Firefox profile shouldn't be in use during the process.\n"
select option in Start Help Exit; do
case $option in
Start)
if [ ! -e user.js ]; then
fQuit 1 "user.js not found in the current directory."
elif [ ! -e prefs.js ]; then
fQuit 1 "prefs.js not found in the current directory."
fi
fFF_check
bakfile="prefs.js.backup.$(date +"%Y-%m-%d_%H%M")"
mv prefs.js "${bakfile}" || fQuit 1 "Operation aborted.\nReason: Could not create backup file $bakfile"
echo -e "\nprefs.js backed up: $bakfile"
echo "Cleaning prefs.js..."
fClean "$bakfile"
fQuit 0 "All done!"
;;
Help)
echo -e "\nThis script creates a backup of your prefs.js file before doing anything."
echo -e "It should be safe, but you can follow these steps if something goes wrong:\n"
echo "1. Make sure Firefox is closed."
echo "2. Delete prefs.js in your profile folder."
echo "3. Delete Invalidprefs.js if you have one in the same folder."
echo "4. Rename or copy your latest backup to prefs.js."
echo "5. Run Firefox and see if you notice anything wrong with it."
echo "6. If you do notice something wrong, especially with your extensions, and/or with the UI, go to about:support, and restart Firefox with add-ons disabled. Then, restart it again normally, and see if the problems were solved."
echo -e "If you are able to identify the cause of your issues, please bring it up on ghacks-user.js GitHub repository.\n"
;;
Exit)
fQuit 0
;;
esac
done

View File

@ -1,61 +0,0 @@
/***
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* --- 57-alpha --- */
/* commented out */
'browser.storageManager.enabled',
'dom.storageManager.enabled',
/* removed from the user.js */
'browser.search.geoip.timeout',
'geo.wifi.xhr.timeout',
'gfx.layerscope.enabled',
'media.webspeech.recognition.enable',
/* moved to RFP ALTERNATIVES */
'dom.w3c_touch_events.enabled',
'media.video_stats.enabled',
/* moved to DEPRECATED/REMOVED */
'browser.bookmarks.showRecentlyBookmarked',
'browser.casting.enabled',
'devtools.webide.autoinstallFxdtAdapters',
'media.eme.chromium-api.enabled',
'social.directories',
'social.enabled',
'social.remote-install.enabled',
'social.share.activationPanelEnabled',
'social.shareDirectory',
'social.toast-notifications.enabled',
'social.whitelist',
/* reset parrot: check your open about:config after running the script */
'_user.js.parrot'
]
if("undefined" === typeof(Services)) {
alert("about:config needs to be the active tab!");
return;
}
let c = 0;
for (let i = 0, len = ops.length; i < len; i++) {
if (Services.prefs.prefHasUserValue(ops[i])) {
Services.prefs.clearUserPref(ops[i]);
if (!Services.prefs.prefHasUserValue(ops[i])) {
console.log("reset", ops[i]);
c++;
} else { console.log("failed to reset", ops[i]); }
}
}
focus();
let d = (c==1) ? " pref" : " prefs";
if (c > 0) {
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
} else { alert("nothing to reset"); }
})();

View File

@ -1,12 +1,10 @@
/***
This will reset the preferences that are under sections 4600 & 4700 in the ghacks user.js
up to and including release 57-alpha. These are the prefs that are no longer necessary,
or they conlfict with, privacy.resistFingerprinting if you have that enabled.
up to and including release 60-beta. These are the prefs that are no longer necessary,
or they conflict with, privacy.resistFingerprinting if you have that enabled.
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
@ -20,9 +18,10 @@
'dom.gamepad.enabled',
'dom.netinfo.enabled',
'media.webspeech.synth.enabled',
'geo.enabled',
'media.video_stats.enabled',
'dom.w3c_touch_events.enabled',
'media.ondevicechange.enabled',
'webgl.enable-debug-renderer-info',
/* section 4700 */
'general.useragent.override',
'general.buildID.override',

View File

@ -1,21 +1,42 @@
/***
This will reset the preferences that have been deprecated by Mozilla
and used in the ghacks user.js up to and including release 57-alpha
and used in the ghacks user.js up to and including release 60-beta
It is in reverse order, so feel free to remove sections that do not apply
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* deprecated */
/* ESR52.x users can remove sections 53-57 but it is not
/* ESR52.x users can remove sections 53-60 but it is not
crucial as your user.js will reinstate them */
/* 60 */
'browser.newtabpage.directory.source',
'browser.newtabpage.enhanced',
'browser.newtabpage.introShown',
'extensions.shield-recipe-client.enabled',
'extensions.shield-recipe-client.api_url',
'browser.newtabpage.activity-stream.enabled',
'dom.workers.enabled',
'view_source.tab',
/* 59 */
'intl.locale.matchOS',
'general.useragent.locale',
'datareporting.healthreport.about.reportUrl',
'dom.flyweb.enabled',
'security.mixed_content.use_hsts',
'security.mixed_content.send_hsts_priming',
'network.http.referer.userControlPolicy',
'security.xpconnect.plugin.unrestricted',
'media.getusermedia.screensharing.allowed_domains',
'camera.control.face_detection.enabled',
'dom.disable_window_status_change',
'dom.idle-observers-api.enabled',
/* 58 : nothing */
/* 57 */
'social.whitelist',
'social.toast-notifications.enabled',

View File

@ -0,0 +1,115 @@
/***
This will reset the preferences that have been removed completely
from the ghacks user.js up to and including release 60-beta
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* removed in ghacks user.js v52-57 */
/* 52-alpha */
'browser.search.reset.enabled',
'browser.search.reset.whitelist',
/* 54-alpha */
'browser.migrate.automigrate.enabled',
'services.sync.enabled',
'webextensions.storage.sync.enabled',
'webextensions.storage.sync.serverURL',
/* 55-alpha */
'dom.keyboardevent.dispatch_during_composition', // default is false anyway
'dom.vr.oculus.enabled', // covered by dom.vr.enabled
'dom.vr.openvr.enabled', // ditto
'dom.vr.osvr.enabled', // ditto
'extensions.pocket.api', // covered by extensions.pocket.enabled
'extensions.pocket.oAuthConsumerKey', // ditto
'extensions.pocket.site', // ditto
/* 56-alpha: none */
/* 57-alpha */
'geo.wifi.xhr.timeout', // covered by geo.enabled
'browser.search.geoip.timeout', // ditto
'media.webspeech.recognition.enable', // default is false anyway
'gfx.layerscope.enabled', // default is false anyway
/* 58-alpha */
// excluding these e10 settings
// 'browser.tabs.remote.autostart',
// 'browser.tabs.remote.autostart.2',
// 'browser.tabs.remote.force-enable',
// 'browser.tabs.remote.separateFileUriProcess',
// 'extensions.e10sBlocksEnabling',
// 'extensions.webextensions.remote',
// 'dom.ipc.processCount',
// 'dom.ipc.shims.enabledWarnings',
// 'dom.ipc.processCount.extension',
// 'dom.ipc.processCount.file',
// 'security.sandbox.content.level',
// 'dom.ipc.plugins.sandbox-level.default',
// 'dom.ipc.plugins.sandbox-level.flash',
// 'security.sandbox.logging.enabled',
'dom.presentation.controller.enabled',
'dom.presentation.discoverable',
'dom.presentation.discovery.enabled',
'dom.presentation.enabled',
'dom.presentation.receiver.enabled',
'dom.presentation.session_transport.data_channel.enable',
/* 59-alpha */
'browser.stopReloadAnimation.enabled',
'browser.tabs.insertRelatedAfterCurrent',
'browser.tabs.loadDivertedInBackground',
'browser.tabs.loadInBackground',
'browser.tabs.selectOwnerOnClose',
'browser.urlbar.clickSelectsAll',
'browser.urlbar.doubleClickSelectsAll',
'media.flac.enabled',
'media.mediasource.enabled',
'media.mediasource.mp4.enabled',
'media.mediasource.webm.audio.enabled',
'media.mediasource.webm.enabled',
'media.mp4.enabled',
'media.ogg.enabled',
'media.ogg.flac.enabled',
'media.opus.enabled',
'media.raw.enabled',
'media.wave.enabled',
'media.webm.enabled',
'media.wmf.amd.vp9.enabled',
'media.wmf.enabled',
'media.wmf.vp9.enabled',
'ui.submenuDelay',
/* 60-beta - these were all at default anyway */
'device.storage.enabled',
'general.useragent.compatMode.firefox',
'network.dns.blockDotOnion',
'network.stricttransportsecurity.preloadlist',
'security.block_script_with_wrong_mime',
'security.fileuri.strict_origin_policy',
'security.sri.enable',
/* reset parrot: check your open about:config after running the script */
'_user.js.parrot'
]
if("undefined" === typeof(Services)) {
alert("about:config needs to be the active tab!");
return;
}
let c = 0;
for (let i = 0, len = ops.length; i < len; i++) {
if (Services.prefs.prefHasUserValue(ops[i])) {
Services.prefs.clearUserPref(ops[i]);
if (!Services.prefs.prefHasUserValue(ops[i])) {
console.log("reset", ops[i]);
c++;
} else { console.log("failed to reset", ops[i]); }
}
}
focus();
let d = (c==1) ? " pref" : " prefs";
if (c > 0) {
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
} else { alert("nothing to reset"); }
})();

View File

@ -1,63 +0,0 @@
/***
This will reset the preferences that have been removed completely
from the ghacks user.js up to and including release 57-alpha
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* removed in ghacks user.js v52-57 */
/* 52-alpha */
'browser.search.reset.enabled',
'browser.search.reset.whitelist',
/* 54-alpha */
'browser.migrate.automigrate.enabled',
'services.sync.enabled',
'webextensions.storage.sync.enabled',
'webextensions.storage.sync.serverURL',
/* 55-alpha */
'dom.keyboardevent.dispatch_during_composition', // default is false anyway
'dom.vr.oculus.enabled', // covered by dom.vr.enabled
'dom.vr.openvr.enabled', // ditto
'dom.vr.osvr.enabled', // ditto
'extensions.pocket.api', // covered by extensions.pocket.enabled
'extensions.pocket.oAuthConsumerKey', // ditto
'extensions.pocket.site', // ditto
/* 56-alpha: none */
/* 57-alpha */
'geo.wifi.xhr.timeout', // covered by geo.enabled
'browser.search.geoip.timeout', // ditto
'media.webspeech.recognition.enable', // default is false anyway
'gfx.layerscope.enabled', // default is false anyway
/* reset parrot: check your open about:config after running the script */
'_user.js.parrot'
]
if("undefined" === typeof(Services)) {
alert("about:config needs to be the active tab!");
return;
}
let c = 0;
for (let i = 0, len = ops.length; i < len; i++) {
if (Services.prefs.prefHasUserValue(ops[i])) {
Services.prefs.clearUserPref(ops[i]);
if (!Services.prefs.prefHasUserValue(ops[i])) {
console.log("reset", ops[i]);
c++;
} else { console.log("failed to reset", ops[i]); }
}
}
focus();
let d = (c==1) ? " pref" : " prefs";
if (c > 0) {
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
} else { alert("nothing to reset"); }
})();

View File

@ -1,409 +0,0 @@
/***
This will reset EVERYTHING that is ACTIVE in the ghacks user.js
release 57-alpha master, but excludes the following:
- prefs removed since publishing on github
- e10s section 1100
- privacy.resistFingerprinting alternatives sections 4600 & 4700
- deprecated section 9999
It does not matter if you clear everything, as a restart will reapply your user.js
Total 477 prefs from 57-alpha master: 118 inactive, 359 active
These have been broken into two scripts for convenience
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* 359 ACTIVE prefs in 57-alpha master */
'accessibility.force_disabled',
'alerts.showFavicons',
'app.update.auto',
'app.update.service.enabled',
'app.update.silent',
'app.update.staging.enabled',
'beacon.enabled',
'breakpad.reportURL',
'browser.aboutHomeSnippets.updateUrl',
'browser.backspace_action',
'browser.bookmarks.max_backups',
'browser.cache.disk.capacity',
'browser.cache.disk.enable',
'browser.cache.disk.smart_size.enabled',
'browser.cache.disk.smart_size.first_run',
'browser.cache.disk_cache_ssl',
'browser.cache.frecency_experiment',
'browser.cache.offline.enable',
'browser.crashReports.unsubmittedCheck.autoSubmit',
'browser.crashReports.unsubmittedCheck.enabled',
'browser.ctrlTab.previews',
'browser.display.use_document_fonts',
'browser.download.folderList',
'browser.download.forbid_open_with',
'browser.download.hide_plugins_without_extensions',
'browser.download.manager.addToRecentDocs',
'browser.download.useDownloadDir',
'browser.eme.ui.enabled',
'browser.fixup.alternate.enabled',
'browser.fixup.hide_user_pass',
'browser.formfill.enable',
'browser.helperApps.deleteTempFileOnExit',
'browser.laterrun.enabled',
'browser.library.activity-stream.enabled',
'browser.link.open_newwindow',
'browser.link.open_newwindow.restriction',
'browser.newtab.preload',
'browser.newtabpage.activity-stream.enabled',
'browser.newtabpage.directory.source',
'browser.newtabpage.enabled',
'browser.newtabpage.enhanced',
'browser.newtabpage.introShown',
'browser.offline-apps.notify',
'browser.onboarding.enabled',
'browser.pagethumbnails.capturing_disabled',
'browser.ping-centre.telemetry',
'browser.rights.3.shown',
'browser.safebrowsing.downloads.remote.enabled',
'browser.safebrowsing.downloads.remote.url',
'browser.safebrowsing.provider.google.reportMalwareMistakeURL',
'browser.safebrowsing.provider.google.reportPhishMistakeURL',
'browser.safebrowsing.provider.google.reportURL',
'browser.safebrowsing.provider.google4.reportMalwareMistakeURL',
'browser.safebrowsing.provider.google4.reportPhishMistakeURL',
'browser.safebrowsing.provider.google4.reportURL',
'browser.safebrowsing.reportPhishURL',
'browser.search.countryCode',
'browser.search.geoip.url',
'browser.search.geoSpecificDefaults',
'browser.search.geoSpecificDefaults.url',
'browser.search.region',
'browser.search.suggest.enabled',
'browser.search.update',
'browser.send_pings',
'browser.send_pings.require_same_host',
'browser.sessionhistory.max_entries',
'browser.sessionstore.interval',
'browser.sessionstore.max_tabs_undo',
'browser.sessionstore.max_windows_undo',
'browser.sessionstore.privacy_level',
'browser.sessionstore.resume_from_crash',
'browser.shell.checkDefaultBrowser',
'browser.shell.shortcutFavicons',
'browser.slowStartup.maxSamples',
'browser.slowStartup.notificationDisabled',
'browser.slowStartup.samples',
'browser.ssl_override_behavior',
'browser.startup.homepage_override.mstone',
'browser.tabs.closeWindowWithLastTab',
'browser.tabs.crashReporting.sendReport',
'browser.tabs.insertRelatedAfterCurrent',
'browser.tabs.loadDivertedInBackground',
'browser.tabs.loadInBackground',
'browser.tabs.selectOwnerOnClose',
'browser.tabs.warnOnClose',
'browser.tabs.warnOnCloseOtherTabs',
'browser.tabs.warnOnOpen',
'browser.taskbar.lists.enabled',
'browser.taskbar.lists.frequent.enabled',
'browser.taskbar.lists.recent.enabled',
'browser.taskbar.lists.tasks.enabled',
'browser.taskbar.previews.enable',
'browser.uitour.enabled',
'browser.uitour.url',
'browser.urlbar.autoFill',
'browser.urlbar.autoFill.typed',
'browser.urlbar.clickSelectsAll',
'browser.urlbar.decodeURLsOnCopy',
'browser.urlbar.doubleClickSelectsAll',
'browser.urlbar.filter.javascript',
'browser.urlbar.maxHistoricalSearchSuggestions',
'browser.urlbar.oneOffSearches',
'browser.urlbar.speculativeConnect.enabled',
// 'browser.urlbar.suggest.bookmark', // this may not get reset by your user.js - see issue #308
// 'browser.urlbar.suggest.history', // ditto
// 'browser.urlbar.suggest.openpage', // ditto
'browser.urlbar.suggest.searches',
'browser.urlbar.trimURLs',
'browser.urlbar.usepreloadedtopurls.enabled',
'browser.urlbar.userMadeSearchSuggestionsChoice',
'browser.xul.error_pages.expert_bad_cert',
'camera.control.face_detection.enabled',
'canvas.capturestream.enabled',
'captivedetect.canonicalURL',
'datareporting.healthreport.about.reportUrl',
'datareporting.healthreport.uploadEnabled',
'datareporting.policy.dataSubmissionEnabled',
'device.storage.enabled',
'devtools.chrome.enabled',
'devtools.debugger.remote-enabled',
'devtools.webide.autoinstallADBHelper',
'devtools.webide.enabled',
'dom.allow_cut_copy',
'dom.allow_scripts_to_close_windows',
'dom.caches.enabled',
'dom.disable_beforeunload',
'dom.disable_window_flip',
'dom.disable_window_move_resize',
'dom.disable_window_open_feature.close',
'dom.disable_window_open_feature.location',
'dom.disable_window_open_feature.menubar',
'dom.disable_window_open_feature.minimizable',
'dom.disable_window_open_feature.personalbar',
'dom.disable_window_open_feature.resizable',
'dom.disable_window_open_feature.status',
'dom.disable_window_open_feature.titlebar',
'dom.disable_window_open_feature.toolbar',
'dom.disable_window_status_change',
'dom.event.clipboardevents.enabled',
'dom.flyweb.enabled',
'dom.idle-observers-api.enabled',
'dom.imagecapture.enabled',
'dom.IntersectionObserver.enabled',
'dom.ipc.plugins.flash.subprocess.crashreporter.enabled',
'dom.ipc.plugins.reportCrashURL',
'dom.popup_allowed_events',
'dom.popup_maximum',
'dom.push.connection.enabled',
'dom.push.enabled',
'dom.push.serverURL',
'dom.push.userAgentID',
'dom.serviceWorkers.enabled',
'dom.vibrator.enabled',
'dom.webaudio.enabled',
'dom.webnotifications.enabled',
'dom.webnotifications.serviceworker.enabled',
'dom.workers.enabled',
'experiments.activeExperiment',
'experiments.enabled',
'experiments.manifest.uri',
'experiments.supported',
'extensions.autoDisableScopes',
'extensions.blocklist.enabled',
'extensions.blocklist.url',
'extensions.enabledScopes',
'extensions.formautofill.addresses.enabled',
'extensions.formautofill.available',
'extensions.formautofill.creditCards.enabled',
'extensions.formautofill.heuristics.enabled',
'extensions.getAddons.cache.enabled',
'extensions.getAddons.showPane',
'extensions.pocket.enabled',
'extensions.shield-recipe-client.api_url',
'extensions.shield-recipe-client.enabled',
'extensions.update.autoUpdateDefault',
'extensions.webcompat-reporter.enabled',
'extensions.webextensions.keepStorageOnUninstall',
'extensions.webextensions.keepUuidOnUninstall',
'extensions.webservice.discoverURL',
'font.blacklist.underline_offset',
'full-screen-api.enabled',
'general.useragent.compatMode.firefox',
'general.useragent.locale',
'general.warnOnAboutConfig',
'geo.wifi.uri',
'gfx.downloadable_fonts.enabled',
'gfx.downloadable_fonts.woff2.enabled',
'gfx.font_rendering.graphite.enabled',
'gfx.font_rendering.opentype_svg.enabled',
'gfx.offscreencanvas.enabled',
'intl.accept_languages',
'intl.locale.matchOS',
'intl.regional_prefs.use_os_locales',
'javascript.options.asmjs',
'javascript.options.wasm',
'javascript.use_us_english_locale',
'keyword.enabled',
'layers.acceleration.disabled',
'layout.css.font-loading-api.enabled',
'layout.css.visited_links_enabled',
'layout.spellcheckDefault',
'lightweightThemes.update.enabled',
'mathml.disabled',
'media.autoplay.enabled',
'media.block-autoplay-until-in-foreground',
'media.eme.enabled',
'media.getusermedia.audiocapture.enabled',
'media.getusermedia.browser.enabled',
'media.getusermedia.screensharing.allowed_domains',
'media.getusermedia.screensharing.enabled',
'media.gmp-gmpopenh264.autoupdate',
'media.gmp-gmpopenh264.enabled',
'media.gmp-manager.updateEnabled',
'media.gmp-manager.url',
'media.gmp-manager.url.override',
'media.gmp-provider.enabled',
'media.gmp-widevinecdm.autoupdate',
'media.gmp-widevinecdm.enabled',
'media.gmp-widevinecdm.visible',
'media.gmp.trial-create.enabled',
'media.navigator.enabled',
'media.navigator.video.enabled',
'media.ondevicechange.enabled',
'media.peerconnection.enabled',
'media.peerconnection.ice.default_address_only',
'media.peerconnection.ice.no_host',
'media.peerconnection.ice.tcp',
'media.peerconnection.identity.enabled',
'media.peerconnection.identity.timeout',
'media.peerconnection.turn.disable',
'media.peerconnection.use_document_iceservers',
'media.peerconnection.video.enabled',
'middlemouse.contentLoadURL',
'network.allow-experiments',
'network.auth.subresource-img-cross-origin-http-auth-allow',
'network.captive-portal-service.enabled',
'network.cookie.cookieBehavior',
'network.cookie.leave-secure-alone',
'network.cookie.thirdparty.sessionOnly',
'network.dns.blockDotOnion',
'network.dns.disablePrefetch',
'network.dns.disablePrefetchFromHTTPS',
'network.http.altsvc.enabled',
'network.http.altsvc.oe',
'network.http.redirection-limit',
'network.http.referer.hideOnionSource',
'network.http.referer.spoofSource',
'network.http.referer.trimmingPolicy',
'network.http.referer.userControlPolicy',
'network.http.referer.XOriginPolicy',
'network.http.referer.XOriginTrimmingPolicy',
'network.http.sendRefererHeader',
'network.http.spdy.enabled',
'network.http.spdy.enabled.deps',
'network.http.spdy.enabled.http2',
'network.http.speculative-parallel-limit',
'network.IDN_show_punycode',
'network.jar.block-remote-files',
'network.jar.open-unsafe-types',
'network.manage-offline-status',
'network.predictor.enable-prefetch',
'network.predictor.enabled',
'network.prefetch-next',
'network.protocol-handler.external.ms-windows-store',
'network.proxy.autoconfig_url.include_path',
'network.proxy.socks_remote_dns',
'network.stricttransportsecurity.preloadlist',
'offline-apps.allow_by_default',
'pdfjs.disabled',
'pdfjs.enableWebGL',
'permissions.manager.defaultsUrl',
'plugin.default.state',
'plugin.defaultXpi.state',
'plugin.scan.plid.all',
'plugin.sessionPermissionNow.intervalInMinutes',
'plugins.click_to_play',
'privacy.clearOnShutdown.cache',
'privacy.clearOnShutdown.cookies',
'privacy.clearOnShutdown.downloads',
'privacy.clearOnShutdown.formdata',
'privacy.clearOnShutdown.history',
'privacy.clearOnShutdown.offlineApps',
'privacy.clearOnShutdown.sessions',
'privacy.clearOnShutdown.siteSettings',
'privacy.cpd.cache',
'privacy.cpd.cookies',
'privacy.cpd.formdata',
'privacy.cpd.history',
'privacy.cpd.offlineApps',
'privacy.cpd.passwords',
'privacy.cpd.sessions',
'privacy.cpd.siteSettings',
'privacy.donottrackheader.enabled',
'privacy.firstparty.isolate',
'privacy.firstparty.isolate.restrict_opener_access',
'privacy.resistFingerprinting',
'privacy.sanitize.sanitizeOnShutdown',
'privacy.sanitize.timeSpan',
'privacy.trackingprotection.ui.enabled',
'security.ask_for_password',
'security.block_script_with_wrong_mime',
'security.cert_pinning.enforcement_level',
'security.csp.enable',
'security.csp.experimentalEnabled',
'security.data_uri.block_toplevel_data_uri_navigations',
'security.dialog_enable_delay',
'security.family_safety.mode',
'security.fileuri.strict_origin_policy',
'security.insecure_field_warning.contextual.enabled',
'security.insecure_password.ui.enabled',
'security.mixed_content.block_active_content',
'security.mixed_content.send_hsts_priming',
'security.mixed_content.use_hsts',
'security.OCSP.enabled',
'security.OCSP.require',
'security.password_lifetime',
'security.pki.sha1_enforcement_level',
'security.sri.enable',
'security.ssl.disable_session_identifiers',
'security.ssl.enable_ocsp_stapling',
'security.ssl.errorReporting.automatic',
'security.ssl.errorReporting.enabled',
'security.ssl.errorReporting.url',
'security.ssl.treat_unsafe_negotiation_as_broken',
'security.tls.enable_0rtt_data',
'security.tls.version.fallback-limit',
'security.tls.version.max',
'security.tls.version.min',
'security.xpconnect.plugin.unrestricted',
'services.blocklist.signing.enforced',
'services.blocklist.update_enabled',
'signon.autofillForms',
'signon.autofillForms.http',
'signon.formlessCapture.enabled',
'signon.storeWhenAutocompleteOff',
'startup.homepage_override_url',
'startup.homepage_welcome_url',
'startup.homepage_welcome_url.additional',
'toolkit.telemetry.archive.enabled',
'toolkit.telemetry.bhrPing.enabled',
'toolkit.telemetry.cachedClientID',
'toolkit.telemetry.enabled',
'toolkit.telemetry.firstShutdownPing.enabled',
'toolkit.telemetry.newProfilePing.enabled',
'toolkit.telemetry.server',
'toolkit.telemetry.shutdownPingSender.enabled',
'toolkit.telemetry.unified',
'toolkit.telemetry.updatePing.enabled',
'ui.submenuDelay',
'ui.use_standins_for_native_colors',
'view_source.tab',
'webchannel.allowObject.urlWhitelist',
'webgl.disable-extensions',
'webgl.disable-fail-if-major-performance-caveat',
'webgl.disabled',
'webgl.dxgl.enabled',
'webgl.enable-debug-renderer-info',
'webgl.enable-webgl2',
'webgl.min_capability_mode',
/* reset parrot: check your open about:config after running the script */
'_user.js.parrot'
]
if("undefined" === typeof(Services)) {
alert("about:config needs to be the active tab!");
return;
}
let c = 0;
for (let i = 0, len = ops.length; i < len; i++) {
if (Services.prefs.prefHasUserValue(ops[i])) {
Services.prefs.clearUserPref(ops[i]);
if (!Services.prefs.prefHasUserValue(ops[i])) {
console.log("reset", ops[i]);
c++;
} else { console.log("failed to reset", ops[i]); }
}
}
focus();
let d = (c==1) ? " pref" : " prefs";
if (c > 0) {
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
} else { alert("nothing to reset"); }
})();

View File

@ -1,167 +0,0 @@
/***
This will reset EVERYTHING that is INACTIVE in the ghacks user.js
release 57-alpha master, but excludes the following:
- prefs removed since publishing on github
- e10s section 1100
- privacy.resistFingerprinting alternatives sections 4600 & 4700
- deprecated section 9999
It does not matter if you clear everything, as a restart will reapply your user.js
Total 477 prefs from 57-alpha master: 118 inactive, 359 active
These have been broken into two scripts for convenience
For instructions see:
https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.1-Resetting-Inactive-Prefs-[Scripts]
***/
(function() {
let ops = [
/* 118 INACTIVE prefs in 57-alpha master */
'accessibility.typeaheadfind',
'app.update.enabled',
'browser.cache.memory.capacity',
'browser.cache.memory.enable',
'browser.chrome.favicons',
'browser.chrome.site_icons',
'browser.download.autohideButton',
'browser.privatebrowsing.autostart',
'browser.safebrowsing.allowOverride',
'browser.safebrowsing.blockedURIs.enabled',
'browser.safebrowsing.downloads.enabled',
'browser.safebrowsing.downloads.remote.block_dangerous',
'browser.safebrowsing.downloads.remote.block_dangerous_host',
'browser.safebrowsing.downloads.remote.block_potentially_unwanted',
'browser.safebrowsing.downloads.remote.block_uncommon',
'browser.safebrowsing.malware.enabled',
'browser.safebrowsing.phishing.enabled',
'browser.safebrowsing.provider.google.gethashURL',
'browser.safebrowsing.provider.google.updateURL',
'browser.safebrowsing.provider.google4.gethashURL',
'browser.safebrowsing.provider.google4.updateURL',
'browser.safebrowsing.provider.mozilla.gethashURL',
'browser.safebrowsing.provider.mozilla.updateURL',
'browser.sessionhistory.max_total_viewers',
'browser.startup.page',
'browser.stopReloadAnimation.enabled',
'browser.storageManager.enabled',
'browser.tabs.loadBookmarksInTabs',
'browser.urlbar.autocomplete.enabled',
'browser.urlbar.maxRichResults',
'clipboard.autocopy',
'dom.event.contextmenu.enabled',
'dom.indexedDB.enabled',
'dom.presentation.controller.enabled',
'dom.presentation.discoverable',
'dom.presentation.discovery.enabled',
'dom.presentation.enabled',
'dom.presentation.receiver.enabled',
'dom.presentation.session_transport.data_channel.enable',
'dom.storage.enabled',
'dom.storageManager.enabled',
'dom.vr.enabled',
'extensions.screenshots.disabled',
'extensions.systemAddon.update.url',
'extensions.update.enabled',
'font.name.monospace.x-unicode',
'font.name.monospace.x-western',
'font.name.sans-serif.x-unicode',
'font.name.sans-serif.x-western',
'font.name.serif.x-unicode',
'font.name.serif.x-western',
'font.system.whitelist',
'full-screen-api.warning.delay',
'full-screen-api.warning.timeout',
'general.autoScroll',
'geo.wifi.logging.enabled',
'gfx.direct2d.disabled',
'javascript.options.baselinejit',
'javascript.options.ion',
'media.flac.enabled',
'media.mediasource.enabled',
'media.mediasource.mp4.enabled',
'media.mediasource.webm.audio.enabled',
'media.mediasource.webm.enabled',
'media.mp4.enabled',
'media.ogg.enabled',
'media.ogg.flac.enabled',
'media.opus.enabled',
'media.raw.enabled',
'media.wave.enabled',
'media.webm.enabled',
'media.wmf.amd.vp9.enabled',
'media.wmf.enabled',
'media.wmf.vp9.enabled',
'network.cookie.lifetime.days',
'network.cookie.lifetimePolicy',
'network.dns.disableIPv6',
'network.dnsCacheEntries',
'network.dnsCacheExpiration',
'network.http.fast-fallback-to-IPv4',
'offline-apps.quota.warn',
'permissions.memory_only',
'places.history.enabled',
'plugin.state.flash',
'privacy.clearOnShutdown.openWindows',
'privacy.cpd.downloads',
'privacy.cpd.openWindows',
'privacy.resistFingerprinting.block_mozAddonManager',
'privacy.trackingprotection.annotate_channels',
'privacy.trackingprotection.enabled',
'privacy.trackingprotection.lower_network_priority',
'privacy.trackingprotection.pbmode.enabled',
'privacy.usercontext.about_newtab_segregation.enabled',
'privacy.userContext.enabled',
'privacy.userContext.longPressBehavior',
'privacy.userContext.ui.enabled',
'privacy.window.maxInnerHeight',
'privacy.window.maxInnerWidth',
'reader.parse-on-load.enabled',
'security.mixed_content.block_display_content',
'security.nocertdb',
'security.ssl.require_safe_negotiation',
'security.ssl3.dhe_rsa_aes_128_sha',
'security.ssl3.dhe_rsa_aes_256_sha',
'security.ssl3.ecdhe_ecdsa_aes_128_sha',
'security.ssl3.ecdhe_rsa_aes_128_sha',
'security.ssl3.rsa_aes_128_sha',
'security.ssl3.rsa_aes_256_sha',
'security.ssl3.rsa_des_ede3_sha',
'services.blocklist.addons.collection',
'services.blocklist.gfx.collection',
'services.blocklist.onecrl.collection',
'services.blocklist.plugins.collection',
'signon.rememberSignons',
'svg.disabled',
'toolkit.cosmeticAnimations.enabled',
'urlclassifier.trackingTable',
'xpinstall.signatures.required',
/* reset parrot: check your open about:config after running the script */
'_user.js.parrot'
]
if("undefined" === typeof(Services)) {
alert("about:config needs to be the active tab!");
return;
}
let c = 0;
for (let i = 0, len = ops.length; i < len; i++) {
if (Services.prefs.prefHasUserValue(ops[i])) {
Services.prefs.clearUserPref(ops[i]);
if (!Services.prefs.prefHasUserValue(ops[i])) {
console.log("reset", ops[i]);
c++;
} else { console.log("failed to reset", ops[i]); }
}
}
focus();
let d = (c==1) ? " pref" : " prefs";
if (c > 0) {
alert("successfully reset " + c + d + "\n\nfor details check the Browser Console (Ctrl+Shift+J)");
} else { alert("nothing to reset"); }
})();

View File

@ -1,5 +1,5 @@
/*** ghacks-user.js troubleshooter.js v1.4 ***/
/*** ghacks-user.js troubleshooter.js v1.5 ***/
(function() {
@ -116,14 +116,6 @@
/* Audio + Video */
'dom.webaudio.enabled',
'media.autoplay.enabled',
'media.flac.enabled',
'media.mp4.enabled',
'media.ogg.enabled',
'media.opus.enabled',
'media.raw.enabled',
'media.wave.enabled',
'media.webm.enabled',
'media.wmf.enabled',
/* Forms */
'browser.formfill.enable',
@ -166,14 +158,6 @@
'privacy.trackingprotection.enabled',
'security.data_uri.block_toplevel_data_uri_navigations',
/* FF User-Interface */
'browser.search.suggest.enabled',
'browser.urlbar.autoFill',
'browser.urlbar.autoFill.typed',
'browser.urlbar.oneOffSearches',
'browser.urlbar.suggest.searches',
'keyword.enabled',
'last.one.without.comma'
]

View File

@ -3,7 +3,7 @@ TITLE ghacks user.js updater
REM ## ghacks-user.js updater for Windows
REM ## author: @claustromaniac
REM ## version: 4.4
REM ## version: 4.5
REM ## instructions: https://github.com/ghacksuserjs/ghacks-user.js/wiki/3.3-Updater-Scripts
SET _myname=%~n0
@ -31,7 +31,6 @@ IF DEFINED _updateb (
DEL /F "[updated]!_myname!.bat.old"
CALL :message "Script updated^!"
TIMEOUT 3 >nul
CLS
GOTO begin
)
REM ## Phase 1 ##
@ -46,11 +45,9 @@ IF DEFINED _updateb (
) >nul 2>&1
IF EXIST "[updated]!_myname!.bat" (
START /min CMD /C "[updated]!_myname!.bat" !_myparams!
EXIT /B
) ELSE (
CALL :message "Failed. Make sure PowerShell is allowed internet access."
TIMEOUT 120 >nul
EXIT /B
)
) ELSE (
IF "!_myname!"=="[updated]" (
@ -68,16 +65,17 @@ IF DEFINED _updateb (
COPY /B /V /Y "!_myname!.bat" "!_myname:~9!.bat"
START CMD /C "!_myname:~9!.bat" !_myparams!
)
EXIT /B
)
EXIT /B
)
:begin
CLS
ECHO:
ECHO:
ECHO: ########################################
ECHO: #### user.js Updater for Windows ####
ECHO: #### by claustromaniac ####
ECHO: #### v4.4 ####
ECHO: #### v4.5 ####
ECHO: ########################################
ECHO:
SET /A "_line=0"
@ -118,7 +116,7 @@ IF DEFINED _log (
:log
SET _log=2
ECHO:##################################################################
CALL :message "%date%, %time%"
ECHO: %date%, %time%
)
IF EXIST user.js.new (DEL /F "user.js.new")
CALL :message "Retrieving latest user.js file from github repository..."
@ -159,7 +157,8 @@ IF EXIST user.js.new (
IF DEFINED _singlebackup (
MOVE /Y user.js user.js.bak >nul
) ELSE (
MOVE /Y user.js "user-backup-!date:/=-!_!time::=.!.js" >nul
SET "_time=!time: =0!"
MOVE /Y user.js "user-backup-!date:/=-!_!_time::=.!.js" >nul
)
REN user.js.new user.js
CALL :message "Update complete."
@ -192,8 +191,9 @@ GOTO :EOF
REM ############ Merge function ############
:merge
SETLOCAL DisableDelayedExpansion
FOR /F tokens^=2^,^*^ delims^=^'^" %%G IN ('FINDSTR /R /C:"^user_pref[ ]*\([ ]*[\"'].*[\"'][ ]*,.*\)[ ]*;" "%~1"') DO (SET "[%%G]=%%H")
FOR /F tokens^=2^,^*^ delims^=^' %%G IN ('FINDSTR /R /C:"^//// --- comment-out --- '[^'][^']*'.*" "%~1"') DO (SET "__unset__%%G=1")
(
FOR /F tokens^=2^,^*^ delims^=^'^" %%G IN ('FINDSTR /B /R /C:"user_pref.*\)[ ]*;" "%~1"') DO (IF NOT "%%H"=="" (SET "%%G=%%H"))
FOR /F "tokens=1,* delims=:" %%I IN ('FINDSTR /N "^" "%~1"') DO (
SET "_temp=%%J"
SETLOCAL EnableDelayedExpansion
@ -206,11 +206,15 @@ SETLOCAL DisableDelayedExpansion
ENDLOCAL
FOR /F tokens^=2^ delims^=^'^" %%K IN ("%%J") DO (
IF NOT "_user.js.parrot"=="%%K" (
IF DEFINED %%K (
IF DEFINED __unset__%%K (
ECHO://%%J
) ELSE (
IF DEFINED [%%K] (
SETLOCAL EnableDelayedExpansion
FOR /F "delims=" %%L IN ("!%%K!") DO (
FOR /F "delims=" %%L IN ("![%%K]!") DO (
ENDLOCAL & ECHO:user_pref("%%K"%%L
SET "%%K="
SET "[%%K]="
)
)
)
) ELSE (ECHO:%%J)
@ -254,7 +258,6 @@ CALL :message " -updatebatch"
ECHO: Update the script itself on execution, before the normal routine.
CALL :message ""
PAUSE
CLS
MODE 80,25
GOTO :begin
REM #####################################

95
updater.sh Normal file → Executable file
View File

@ -1,12 +1,14 @@
#!/bin/bash
#!/usr/bin/env bash
### ghacks-user.js updater for Mac/Linux
## author: @overdodactyl
## version: 1.2
## version: 1.3
## DON'T GO HIGHER THAN VERSION x.9 !! ( because of ASCII comparison in check_for_update() )
ghacksjs="https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/user.js"
echo -e "\nThis script should be run from your Firefox profile directory.\n"
updater="https://raw.githubusercontent.com/ghacksuserjs/ghacks-user.js/master/updater.sh"
update_pref=${1:--ask}
currdir=$(pwd)
@ -19,26 +21,60 @@ if [ -z "$sfp" ]; then sfp=${BASH_SOURCE[0]}; fi
## change directory to the Firefox profile directory
cd "$(dirname "${sfp}")"
echo -e "Updating the user.js for Firefox profile:\n$(pwd)\n"
## Used to check if a new version of updater.sh is available
update_available="no"
check_for_update () {
online_version="$(curl -s ${updater} | sed -n '5 s/.*[[:blank:]]\([[:digit:]]*\.[[:digit:]]*\)/\1/p')"
path_to_script="$(dirname "${sfp}")/updater.sh"
current_version="$(sed -n '5 s/.*[[:blank:]]\([[:digit:]]*\.[[:digit:]]*\)/\1/p' "$path_to_script")"
if [[ "$current_version" < "$online_version" ]]; then
update_available="yes"
fi
}
if [ -e user.js ]; then
## Used to backup the current script, and download and execute the latest version of updater.sh
update_script () {
echo -e "This script will be backed up and the latest version of updater.sh will be executed.\n"
mv updater.sh "updater.sh.backup.$(date +"%Y-%m-%d_%H%M")"
curl -O ${updater} && echo -e "\nThe latest updater script has been downloaded\n"
# make new file executable
chmod +x updater.sh
# execute new updater script
./updater.sh -donotupdate
# exit script
exit 1
}
main () {
## create backup folder if it doesn't exist
mkdir -p userjs_backups;
echo -e "\nThis script should be run from your Firefox profile directory.\n"
echo -e "Updating the user.js for Firefox profile:\n$(pwd)\n"
if [ -e user.js ]; then
echo "Your current user.js file for this profile will be backed up and the latest ghacks version from github will take its place."
echo -e "\nIf currently using the ghacks user.js, please compare versions:"
echo " Available online: $(curl -s ${ghacksjs} | sed -n '4p')"
echo " Currently using: $(sed -n '4p' user.js)"
else
else
echo "A user.js file does not exist in this profile. If you continue, the latest ghacks version from github will be downloaded."
fi
fi
echo -e "\nIf a user-overrides.js file exists in this profile, it will be appended to the user.js.\n"
echo -e "\nIf a user-overrides.js file exists in this profile, it will be appended to the user.js.\n"
read -p "Continue Y/N? " -n 1 -r
echo -e "\n\n"
read -p "Continue Y/N? " -n 1 -r
echo -e "\n\n"
if [[ $REPLY =~ ^[Yy]$ ]]; then
if [[ $REPLY =~ ^[Yy]$ ]]; then
if [ -e user.js ]; then
# backup current user.js
bakfile="user.js.backup.$(date +"%Y-%m-%d_%H%M")"
bakfile="userjs_backups/user.js.backup.$(date +"%Y-%m-%d_%H%M")"
mv user.js "${bakfile}" && echo "Your previous user.js file was backed up: ${bakfile}"
fi
@ -50,9 +86,34 @@ if [[ $REPLY =~ ^[Yy]$ ]]; then
echo "user-overrides.js file found"
cat user-overrides.js >> user.js && echo "user-overrides.js has been appended to user.js"
fi
else
else
echo "Process aborted"
fi
fi
## change directory back to the original working directory
cd "${currdir}"
## change directory back to the original working directory
cd "${currdir}"
}
update_pref="$(echo $update_pref | tr '[A-Z]' '[a-z]')"
if [ $update_pref = "-donotupdate" ]; then
main
else
check_for_update
if [ $update_available = "no" ]; then
main
else
## there is an update available
if [ $update_pref = "-update" ]; then
## update without asking
update_script
else
read -p "There is a newer version of updater.sh available. Download and execute? Y/N? " -n 1 -r
echo -e "\n\n"
if [[ $REPLY =~ ^[Yy]$ ]]; then
update_script
else
main
fi
fi
fi
fi

1160
user.js

File diff suppressed because it is too large Load Diff