Fix firefox fingerprint protection.

This commit is contained in:
Tom Alexander 2024-07-21 11:25:51 -04:00
parent 1e47ff3f64
commit 3a63d4d307
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
2 changed files with 10 additions and 1 deletions

View File

@ -33,7 +33,7 @@ firefox_config:
browser.urlbar.speculativeConnect.enabled: false
# Do not resist fingerprinting because that tells websites to use light mode.
# https://bugzilla.mozilla.org/show_bug.cgi?id=1732114
privacy.resistFingerprinting: true
privacy.resistFingerprinting: null # (default false)
# Instead, enable fingerprinting protection, which allows configuring an override.
privacy.fingerprintingProtection: true
# Allow sending dark mode preference to websites.

View File

@ -10,12 +10,21 @@
register: firefox_about_config
- name: Configure Firefox about:config
when: item[1].value != None
lineinfile:
path: "{{ item[0].path }}"
regexp: '"{{ item[1].key }}", [^")\n]*\)'
line: 'user_pref("{{ item[1].key }}", {{ item[1].value | to_json }});'
loop: "{{ firefox_about_config.files | product(firefox_config | dict2items) | list }}"
- name: Configure Firefox about:config
when: item[1].value == None
lineinfile:
path: "{{ item[0].path }}"
regexp: '"{{ item[1].key }}", [^")\n]*\)'
state: absent
loop: "{{ firefox_about_config.files | product(firefox_config | dict2items) | list }}"
- import_tasks: tasks/peruser_freebsd.yaml
when: 'os_flavor == "freebsd"'