Commit c6627585 authored by henry's avatar henry Committed by morgan
Browse files

fixup! BB 40925: Implemented the Security Level component

BB 45201: Move security level settings to the settings config.
parent 89150102
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -7,6 +7,10 @@
import { SettingGroupManager } from "chrome://browser/content/preferences/config/SettingGroupManager.mjs";
import { Preferences } from "chrome://global/content/preferences/Preferences.mjs";

ChromeUtils.importESModule(
  "chrome://browser/content/securitylevel/config/security-level.mjs",
  { global: "current" }
);
ChromeUtils.importESModule(
  "chrome://browser/content/preferences/config/protections-from-apps.mjs",
  { global: "current" }
+1 −0
Original line number Diff line number Diff line
@@ -409,6 +409,7 @@ const CONFIG_PANES = Object.freeze({
      "ipprotection",
      "cookiesAndSiteData2",
      "history2",
      "securityLevelGroup",
      "nonTechnicalPrivacy2",
      "dnsOverHttps",
      "connectionLink",
+2 −1
Original line number Diff line number Diff line
@@ -43,7 +43,6 @@
    href="chrome://browser/content/preferences/letterboxing.css"
  />

  <link rel="stylesheet" href="chrome://browser/content/securitylevel/securityLevelPreferences.css" />
  <link rel="stylesheet" href="chrome://browser/content/torpreferences/torPreferences.css" />
  <link rel="stylesheet" href="chrome://browser/content/onionservices/authPreferences.css" />

@@ -108,6 +107,8 @@
  <script type="module" src="chrome://browser/content/preferences/widgets/update-information.mjs"></script>
  <script type="module" src="chrome://browser/content/preferences/widgets/update-state.mjs"></script>
  <script type="module" src="chrome://browser/content/ipprotection/bandwidth-usage.mjs"></script>
  <script type="module" src="chrome://browser/content/securitylevel/widgets/security-level-description.mjs"></script>
  <script type="module" src="chrome://browser/content/securitylevel/widgets/security-level-display.mjs"></script>
  <script type="module" src="chrome://browser/content/torpreferences/widgets/tor-bridges-display.mjs"></script>
  <script type="module" src="chrome://browser/content/torpreferences/widgets/tor-connection-assist-banner.mjs"></script>
  <script type="module" src="chrome://browser/content/torpreferences/widgets/tor-connection-status.mjs"></script>
+1 −1
Original line number Diff line number Diff line
@@ -579,7 +579,7 @@
  <html:h1 data-l10n-id="security-header"/>
</hbox>

#include ../securitylevel/content/securityLevelPreferences.inc.xhtml
<html:setting-group groupid="securityLevelGroup" data-category="panePrivacy" hidden="true" data-srd-migrated=""></html:setting-group>

<!-- addons, forgery (phishing) UI Security -->
<html:setting-group groupid="browsingProtection" data-category="panePrivacy" hidden="true" data-srd-migrated=""></html:setting-group>
+1 −18
Original line number Diff line number Diff line
@@ -60,13 +60,6 @@ ChromeUtils.defineLazyGetter(lazy, "gParentalControlsService", () =>
    : null
);

// TODO: module import via ChromeUtils.defineModuleGetter
XPCOMUtils.defineLazyScriptGetter(
  this,
  ["SecurityLevelPreferences"],
  "chrome://browser/content/securitylevel/securityLevel.js"
);

XPCOMUtils.defineLazyPreferenceGetter(
  this,
  "gIsFirstPartyIsolated",
@@ -150,16 +143,6 @@ function initTCPStandardSection() {
var gPrivacyPane = {
  _pane: null,

  /**
   * Show the Security Level UI
   */
  _initSecurityLevel() {
    SecurityLevelPreferences.init();
    window.addEventListener("unload", () => SecurityLevelPreferences.uninit(), {
      once: true,
    });
  },

  /**
   * Whether the prompt to restart Firefox should appear when changing the autostart pref.
   */
@@ -654,6 +637,7 @@ var gPrivacyPane = {
    initSettingGroup("etpReset");
    initSettingGroup("etpCustomize");
    initSettingGroup("networkProxy");
    initSettingGroup("securityLevelGroup");

    /* Initialize Content Blocking */
    this.initContentBlocking();
@@ -663,7 +647,6 @@ var gPrivacyPane = {
    this.networkCookieBehaviorReadPrefs();
    this._initTrackingProtectionExtensionControl();
    this._ensureTrackingProtectionExceptionListMigration();
    this._initSecurityLevel();

    Preferences.get("privacy.trackingprotection.enabled").on(
      "change",
Loading