mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Bug 1507230 - dom.security.featurePolicy.webidl.enabled pref controls the exposing of document.policy and HTMLIFrameElement.policy attributes, r=ckerschb
This commit is contained in:
parent
3c9a4a719c
commit
5e3dc65e1b
@ -50,7 +50,8 @@ var gTestWindows = [
|
||||
{ test: "file_fullscreen-event-order.html" },
|
||||
{ test: "file_fullscreen-featurePolicy.html",
|
||||
prefs: [["dom.security.featurePolicy.enabled", true],
|
||||
["dom.security.featurePolicy.header.enabled", true]] },
|
||||
["dom.security.featurePolicy.header.enabled", true],
|
||||
["dom.security.featurePolicy.webidl.enabled", true]] },
|
||||
];
|
||||
|
||||
var testWindow = null;
|
||||
|
@ -2,6 +2,7 @@
|
||||
prefs =
|
||||
dom.security.featurePolicy.enabled=true
|
||||
dom.security.featurePolicy.header.enabled=true
|
||||
dom.security.featurePolicy.webidl.enabled=true
|
||||
support-files =
|
||||
empty.html
|
||||
test_parser.html^headers^
|
||||
|
@ -48,6 +48,7 @@ function nextTest() {
|
||||
SpecialPowers.pushPrefEnv({"set": [
|
||||
["dom.security.featurePolicy.enabled", true],
|
||||
["dom.security.featurePolicy.header.enabled", true],
|
||||
["dom.security.featurePolicy.webidl.enabled", true],
|
||||
]}).then(nextTest);
|
||||
</script>
|
||||
</body>
|
||||
|
@ -550,6 +550,6 @@ Document implements DocumentOrShadowRoot;
|
||||
|
||||
// https://wicg.github.io/feature-policy/#policy
|
||||
partial interface Document {
|
||||
[SameObject, Pref="dom.security.featurePolicy.enabled"]
|
||||
[SameObject, Pref="dom.security.featurePolicy.webidl.enabled"]
|
||||
readonly attribute Policy policy;
|
||||
};
|
||||
|
@ -72,7 +72,7 @@ HTMLIFrameElement implements BrowserElement;
|
||||
|
||||
// https://wicg.github.io/feature-policy/#policy
|
||||
partial interface HTMLIFrameElement {
|
||||
[SameObject, Pref="dom.security.featurePolicy.enabled"]
|
||||
[SameObject, Pref="dom.security.featurePolicy.webidl.enabled"]
|
||||
readonly attribute Policy policy;
|
||||
|
||||
[CEReactions, SetterThrows, Pure, Pref="dom.security.featurePolicy.enabled"]
|
||||
|
@ -1799,6 +1799,13 @@ VARCACHE_PREF(
|
||||
dom_security_featurePolicy_header_enabled,
|
||||
bool, PREF_VALUE
|
||||
)
|
||||
|
||||
// Expose the 'policy' attribute in document and HTMLIFrameElement
|
||||
VARCACHE_PREF(
|
||||
"dom.security.featurePolicy.webidl.enabled",
|
||||
dom_security_featurePolicy_webidl_enabled,
|
||||
bool, PREF_VALUE
|
||||
)
|
||||
#undef PREF_VALUE
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
|
@ -1,2 +1,2 @@
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
lsan-allowed: [Alloc, MakeUnique, Malloc, NewPage, Realloc, mozilla::EMEDecryptor::EMEDecryptor, mozilla::SchedulerGroup::CreateEventTargetFor, CreateCDMProxy, mozilla::dom::MediaKeys::CreateCDMProxy, mozilla::dom::nsIContentChild::GetConstructedEventTarget]
|
||||
|
@ -1,2 +1,2 @@
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.payments.request.enabled:true, dom.reporting.enabled:true, dom.reporting.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.webmidi.enabled:true, dom.vr.enabled:true]
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.payments.request.enabled:true, dom.reporting.enabled:true, dom.reporting.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true, dom.webmidi.enabled:true, dom.vr.enabled:true]
|
||||
lsan-allowed: []
|
||||
|
@ -1,2 +1,2 @@
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
lsan-allowed: []
|
||||
|
@ -1,2 +1,2 @@
|
||||
prefs: [media.navigator.permission.disabled:true, media.navigator.streams.fake:true, dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [media.navigator.permission.disabled:true, media.navigator.streams.fake:true, dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
lsan-allowed: [Alloc, NewEmptyScopeData, XPCWrappedNative::GetNewOrUsed, js_new, mozilla::BasePrincipal::CreateCodebasePrincipal, mozilla::dom::ChromeUtils::GenerateQI, nsStringBuffer::Alloc]
|
||||
|
@ -1 +1 @@
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
|
@ -1 +1 @@
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [dom.security.featurePolicy.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
|
@ -1 +1 @@
|
||||
prefs: [dom.vr.enabled:true,dom.security.featurePolicy.enabled:true,dom.security.featurePolicy.header.enabled:true]
|
||||
prefs: [dom.vr.enabled:true,dom.security.featurePolicy.enabled:true,dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true]
|
||||
|
Loading…
Reference in New Issue
Block a user