Browse Source

Block firefox telemetry

Bob Mottram 6 years ago
parent
commit
95453f8205
2 changed files with 19 additions and 0 deletions
  1. 16
    0
      src/freedombone-utils-firewall
  2. 3
    0
      src/freedombone-utils-setup

+ 16
- 0
src/freedombone-utils-firewall View File

@@ -47,6 +47,22 @@ function save_firewall_settings {
47 47
     fi
48 48
 }
49 49
 
50
+function block_firefox_telemetry {
51
+    # This shouldn't be needed on a server, but we'll do it anyway
52
+    # to be on the safe side
53
+    # Within firefox source code see submit_telemetry_data.py
54
+
55
+    FIREFOX_TELEMETRY_IP='52.88.27.118'
56
+
57
+    if grep "$FIREFOX_TELEMETRY_IP" /etc/firewall.conf; then
58
+        return
59
+    fi
60
+
61
+    iptables -A INPUT -s $FIREFOX_TELEMETRY_IP -j DROP
62
+    iptables -A OUTPUT -s $FIREFOX_TELEMETRY_IP -j DROP
63
+    save_firewall_settings
64
+}
65
+
50 66
 function firewall_block_bad_ip_ranges {
51 67
     if [ "$INSTALLING_MESH" ]; then
52 68
         return

+ 3
- 0
src/freedombone-utils-setup View File

@@ -720,6 +720,9 @@ function setup_firewall {
720 720
     function_check configure_firewall
721 721
     configure_firewall
722 722
 
723
+    function_check block_firefox_telemetry
724
+    block_firefox_telemetry
725
+
723 726
     function_check configure_firewall_ping
724 727
     configure_firewall_ping
725 728