mozilla / policy-templates

Policy Templates for Firefox
Mozilla Public License 2.0
1.15k stars 415 forks source link

Bug: DNSOverHTTPS policy ignores other settings when "Locked": true is used. #1096

Closed EmerGen-AI closed 7 months ago

EmerGen-AI commented 7 months ago
    "DNSOverHTTPS": {
      "Enabled":  false,
      "Locked":  true,
      "Fallback": false
    }
EmerGen-AI commented 7 months ago

Adding the above policy will lock DNSOverHTTPS settings to the default (Cloudflare DNS), rather than locking it to Disabled/Off. (Seems to ignore the "Enabled": false flag)

Environment: Ubuntu 24.04

qupig commented 7 months ago

Yes, I can reproduce this, I'm guessing they just respect Fallback over Enabled (Because the Fallback behavior only exists when DoH is turned on), and removing Fallback or set it true works as expected.

EmerGen-AI commented 7 months ago

Ah, excellent. Much appreciated.

mkaply commented 7 months ago

Yeah, just to confirm what @qupig said, these are mapping to one preference behind the scenes which made thing kind of clunky.

If you're curious:

https://searchfox.org/mozilla-central/source/browser/components/enterprisepolicies/Policies.sys.mjs#1053