aboutsummaryrefslogtreecommitdiff
path: root/profiles/replaceAllUrls.nix
diff options
context:
space:
mode:
authortilpner2020-06-15 09:53:06 +0200
committertilpner2020-06-15 09:53:06 +0200
commit367b0c114f38d5c332f5ee971ad13dd69e302dec (patch)
treeec0c5ee3e7e1f0a30517599e51bd0c8172635158 /profiles/replaceAllUrls.nix
parent2992d92e6ce0d7c96ccded0747d8815d8cfed956 (diff)
downloadfirefox-profiles-367b0c114f38d5c332f5ee971ad13dd69e302dec.tar.gz
firefox-profiles-367b0c114f38d5c332f5ee971ad13dd69e302dec.tar.xz
firefox-profiles-367b0c114f38d5c332f5ee971ad13dd69e302dec.zip
WIP towards module based configuration
Diffstat (limited to 'profiles/replaceAllUrls.nix')
-rw-r--r--profiles/replaceAllUrls.nix35
1 files changed, 20 insertions, 15 deletions
diff --git a/profiles/replaceAllUrls.nix b/profiles/replaceAllUrls.nix
index 8b71033..4c047ea 100644
--- a/profiles/replaceAllUrls.nix
+++ b/profiles/replaceAllUrls.nix
@@ -1,30 +1,35 @@
-{ ... }:
+{ config, lib, ... }:
+with lib;
let
# Requirements:
# - is valid connection target (from FF perspective)
# - doesn't have any negative effects on the user privacy or security
h = "127.0.0.1";
- u = "http://${h}";
+ u = lib.mkForce "http://${h}";
in {
- meta.description = ''
- Firefox communicates with external services in many different ways. Not all of them
- happen on startup, and they can be triggered on different intervals.
+ options.dataFrugality.replaceAllUrls = mkOption {
+ type = types.bool;
+ default = false;
+ description = ''
+ Firefox communicates with external services in many different ways. Not all of them
+ happen on startup, and they can be triggered on different intervals.
- This is a desperate effort to prevent as much of that communication as possible, by depriving FF of all configurable
- URLs. It will break things, put the users security/privacy at risk, and probably shouldn't be enabled.
+ This is a desperate effort to prevent as much of that communication as possible, by depriving FF of all configurable
+ URLs. It will break things, put the users security/privacy at risk, and probably shouldn't be enabled.
- Even so, this list may be insufficient. It was created manually from an about:config listing
- for the searchterms "url", "uri", "endpoint", and "server", so it will miss hidden (but defaulted) and hardcoded URLs.
+ Even so, this list may be insufficient. It was created manually from an about:config listing
+ for the searchterms "url", "uri", "endpoint", and "server", so it will miss hidden (but defaulted) and hardcoded URLs.
- Further consideration for the placeholder value is required.
+ Further consideration for the placeholder value is required.
- Known issues:
- - This list will get outdated rather quickly
- - Typos and renaming of keys are not caught in any way
- '';
+ Known issues:
+ * This list will get outdated rather quickly
+ * Typos and renaming of keys are not caught in any way
+ '';
+ };
- preferences = {
+ config.preferences = lib.mkIf config.dataFrugality.replaceAllUrls {
app = {
feedback.baseURL = u;
releaseNotesURL = u;