Index: content/renderer/render_frame_proxy.cc |
diff --git a/content/renderer/render_frame_proxy.cc b/content/renderer/render_frame_proxy.cc |
index fe58b65b758864d090f39cd88d2da9fc6ec89e2e..445f3520a94a55018996054c26b8eb46d56455a3 100644 |
--- a/content/renderer/render_frame_proxy.cc |
+++ b/content/renderer/render_frame_proxy.cc |
@@ -10,6 +10,7 @@ |
#include "base/command_line.h" |
#include "base/lazy_instance.h" |
+#include "content/child/feature_policy/feature_policy_platform.h" |
#include "content/child/web_url_request_util.h" |
#include "content/child/webmessageportchannel_impl.h" |
#include "content/common/content_security_policy_header.h" |
@@ -49,22 +50,6 @@ static base::LazyInstance<RoutingIDProxyMap> g_routing_id_proxy_map = |
typedef std::map<blink::WebFrame*, RenderFrameProxy*> FrameMap; |
base::LazyInstance<FrameMap> g_frame_map = LAZY_INSTANCE_INITIALIZER; |
-blink::WebParsedFeaturePolicy ToWebParsedFeaturePolicy( |
- const ParsedFeaturePolicy& parsed_whitelists) { |
- std::vector<blink::WebFeaturePolicy::ParsedWhitelist> result; |
- for (const FeaturePolicyParsedWhitelist& whitelist : parsed_whitelists) { |
- blink::WebFeaturePolicy::ParsedWhitelist web_whitelist; |
- web_whitelist.featureName = |
- blink::WebString::fromUTF8(whitelist.feature_name); |
- web_whitelist.matchesAllOrigins = whitelist.matches_all_origins; |
- std::vector<blink::WebSecurityOrigin> web_origins; |
- for (const url::Origin& origin : whitelist.origins) |
- web_origins.push_back(origin); |
- result.push_back(web_whitelist); |
- } |
- return result; |
-} |
- |
} // namespace |
// static |
@@ -242,7 +227,7 @@ void RenderFrameProxy::SetReplicatedState(const FrameReplicationState& state) { |
web_frame_->setReplicatedPotentiallyTrustworthyUniqueOrigin( |
state.has_potentially_trustworthy_unique_origin); |
web_frame_->setReplicatedFeaturePolicyHeader( |
- ToWebParsedFeaturePolicy(state.feature_policy_header)); |
+ FeaturePolicyHeaderToWeb(state.feature_policy_header)); |
web_frame_->resetReplicatedContentSecurityPolicy(); |
for (const auto& header : state.accumulated_csp_headers) |