Index: third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp |
diff --git a/third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp b/third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp |
index c4f8498d80cb7ecca3e832e800f12b167c7befd4..19cff3d50dbd795a8a8d087ed36bdb2c2e8c9fb2 100644 |
--- a/third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp |
+++ b/third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp |
@@ -15,6 +15,7 @@ |
#include "core/html/HTMLFrameOwnerElement.h" |
#include "core/layout/LayoutObject.h" |
#include "core/page/Page.h" |
+#include "platform/feature_policy/FeaturePolicy.h" |
#include "platform/heap/Handle.h" |
#include "public/platform/WebFeaturePolicy.h" |
#include "public/platform/WebFloatRect.h" |
@@ -431,8 +432,12 @@ void WebRemoteFrameImpl::setReplicatedFeaturePolicyHeader( |
Frame* parentFrame = frame()->client()->parent(); |
parentFeaturePolicy = parentFrame->securityContext()->getFeaturePolicy(); |
} |
- frame()->securityContext()->initializeFeaturePolicy(parsedHeader, |
- parentFeaturePolicy); |
+ const WebParsedFeaturePolicy containerPolicy = |
+ getContainerPolicyFromAllowedFeatures( |
+ frame()->owner()->allowedFeatures(), |
+ frame()->securityContext()->getSecurityOrigin()); |
+ frame()->securityContext()->initializeFeaturePolicy( |
+ parsedHeader, containerPolicy, parentFeaturePolicy); |
} |
} |