Commit c56a67c4 authored by Michael Kaply's avatar Michael Kaply
Browse files

Bug 1544533 - Add a policy for local file links. r=Felipe,flod

Differential Revision: https://phabricator.services.mozilla.com/D27566

--HG--
extra : moz-landing-system : lando
parent ceb466e4
......@@ -679,6 +679,17 @@ var Policies = {
},
},
"LocalFileLinks": {
onBeforeAddons(manager, param) {
// If there are existing capabilities, lock them with the policy pref.
let policyNames = Services.prefs.getCharPref("capability.policy.policynames", "").split(" ");
policyNames.push("localfilelinks_policy");
setAndLockPref("capability.policy.policynames", policyNames.join(" "));
setAndLockPref("capability.policy.localfilelinks_policy.checkloaduri.enabled", "allAccess");
setAndLockPref("capability.policy.localfilelinks_policy.sites", param.join(" "));
},
},
"NetworkPrediction": {
onBeforeAddons(manager, param) {
setAndLockPref("network.dns.disablePrefetch", !param);
......
......@@ -403,6 +403,13 @@
}
},
"LocalFileLinks": {
"type": "array",
"items": {
"type": "string"
}
},
"NetworkPrediction": {
"type": "boolean"
},
......
......@@ -97,6 +97,8 @@ policy-Homepage = Set and optionally lock the homepage.
policy-InstallAddonsPermission = Allow certain websites to install add-ons.
policy-LocalFileLinks = Allow specific websites to link to local files.
policy-NetworkPrediction = Enable or disable network prediction (DNS prefetching).
policy-NewTabPage = Enable or disable the New Tab page.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment