Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(207)

Side by Side Diff: content/browser/frame_host/frame_tree_node.cc

Issue 2445993006: [WIP] Upgrade-insecure-request: upgrade insecurely-redirected requests.
Patch Set: bugfix Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/frame_host/frame_tree_node.h" 5 #include "content/browser/frame_host/frame_tree_node.h"
6 6
7 #include <queue> 7 #include <queue>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 } 260 }
261 261
262 void FrameTreeNode::SetInsecureRequestPolicy( 262 void FrameTreeNode::SetInsecureRequestPolicy(
263 blink::WebInsecureRequestPolicy policy) { 263 blink::WebInsecureRequestPolicy policy) {
264 if (policy == replication_state_.insecure_request_policy) 264 if (policy == replication_state_.insecure_request_policy)
265 return; 265 return;
266 render_manager_.OnEnforceInsecureRequestPolicy(policy); 266 render_manager_.OnEnforceInsecureRequestPolicy(policy);
267 replication_state_.insecure_request_policy = policy; 267 replication_state_.insecure_request_policy = policy;
268 } 268 }
269 269
270 blink::WebInsecureRequestPolicy FrameTreeNode::GetInsecureRequestPolicy()
271 const {
272 return replication_state_.insecure_request_policy;
273 }
274
270 void FrameTreeNode::SetPendingSandboxFlags( 275 void FrameTreeNode::SetPendingSandboxFlags(
271 blink::WebSandboxFlags sandbox_flags) { 276 blink::WebSandboxFlags sandbox_flags) {
272 pending_sandbox_flags_ = sandbox_flags; 277 pending_sandbox_flags_ = sandbox_flags;
273 278
274 // Subframes should always inherit their parent's sandbox flags. 279 // Subframes should always inherit their parent's sandbox flags.
275 if (parent()) 280 if (parent())
276 pending_sandbox_flags_ |= parent()->effective_sandbox_flags(); 281 pending_sandbox_flags_ |= parent()->effective_sandbox_flags();
277 } 282 }
278 283
279 bool FrameTreeNode::IsDescendantOf(FrameTreeNode* other) const { 284 bool FrameTreeNode::IsDescendantOf(FrameTreeNode* other) const {
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
505 } 510 }
506 return parent_->child_at(i + relative_offset); 511 return parent_->child_at(i + relative_offset);
507 } 512 }
508 } 513 }
509 514
510 NOTREACHED() << "FrameTreeNode not found in its parent's children."; 515 NOTREACHED() << "FrameTreeNode not found in its parent's children.";
511 return nullptr; 516 return nullptr;
512 } 517 }
513 518
514 } // namespace content 519 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/frame_host/frame_tree_node.h ('k') | content/browser/frame_host/navigation_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698