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

Side by Side Diff: content/renderer/render_frame_impl.cc

Issue 1710283003: OOPIF: Handle cross-site frames being blocked by X-Frame-Options or CSP. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Split off the relaxed DCHECK in OnCrossSiteResponse into separate CL Created 4 years, 9 months 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
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | content/test/data/frame-ancestors-none.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/renderer/render_frame_impl.h" 5 #include "content/renderer/render_frame_impl.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 1407 matching lines...) Expand 10 before | Expand all | Expand 10 after
1418 OnTextSurroundingSelectionRequest) 1418 OnTextSurroundingSelectionRequest)
1419 IPC_MESSAGE_HANDLER(FrameMsg_SetAccessibilityMode, 1419 IPC_MESSAGE_HANDLER(FrameMsg_SetAccessibilityMode,
1420 OnSetAccessibilityMode) 1420 OnSetAccessibilityMode)
1421 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree, 1421 IPC_MESSAGE_HANDLER(AccessibilityMsg_SnapshotTree,
1422 OnSnapshotAccessibilityTree) 1422 OnSnapshotAccessibilityTree)
1423 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener) 1423 IPC_MESSAGE_HANDLER(FrameMsg_UpdateOpener, OnUpdateOpener)
1424 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation) 1424 IPC_MESSAGE_HANDLER(FrameMsg_CommitNavigation, OnCommitNavigation)
1425 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateSandboxFlags, OnDidUpdateSandboxFlags) 1425 IPC_MESSAGE_HANDLER(FrameMsg_DidUpdateSandboxFlags, OnDidUpdateSandboxFlags)
1426 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties, 1426 IPC_MESSAGE_HANDLER(FrameMsg_SetFrameOwnerProperties,
1427 OnSetFrameOwnerProperties) 1427 OnSetFrameOwnerProperties)
1428 IPC_MESSAGE_HANDLER(FrameMsg_BlockedLoad, OnBlockedLoad)
1428 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus) 1429 IPC_MESSAGE_HANDLER(FrameMsg_AdvanceFocus, OnAdvanceFocus)
1429 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame) 1430 IPC_MESSAGE_HANDLER(FrameMsg_SetFocusedFrame, OnSetFocusedFrame)
1430 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings, 1431 IPC_MESSAGE_HANDLER(FrameMsg_SetTextTrackSettings,
1431 OnTextTrackSettingsChanged) 1432 OnTextTrackSettingsChanged)
1432 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent) 1433 IPC_MESSAGE_HANDLER(FrameMsg_PostMessageEvent, OnPostMessageEvent)
1433 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation) 1434 IPC_MESSAGE_HANDLER(FrameMsg_FailedNavigation, OnFailedNavigation)
1434 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks, 1435 IPC_MESSAGE_HANDLER(FrameMsg_GetSavableResourceLinks,
1435 OnGetSavableResourceLinks) 1436 OnGetSavableResourceLinks)
1436 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks, 1437 IPC_MESSAGE_HANDLER(FrameMsg_GetSerializedHtmlWithLocalLinks,
1437 OnGetSerializedHtmlWithLocalLinks) 1438 OnGetSerializedHtmlWithLocalLinks)
(...skipping 597 matching lines...) Expand 10 before | Expand all | Expand 10 after
2035 void RenderFrameImpl::OnDidUpdateSandboxFlags(blink::WebSandboxFlags flags) { 2036 void RenderFrameImpl::OnDidUpdateSandboxFlags(blink::WebSandboxFlags flags) {
2036 frame_->setFrameOwnerSandboxFlags(flags); 2037 frame_->setFrameOwnerSandboxFlags(flags);
2037 } 2038 }
2038 2039
2039 void RenderFrameImpl::OnSetFrameOwnerProperties( 2040 void RenderFrameImpl::OnSetFrameOwnerProperties(
2040 const blink::WebFrameOwnerProperties& frame_owner_properties) { 2041 const blink::WebFrameOwnerProperties& frame_owner_properties) {
2041 DCHECK(frame_); 2042 DCHECK(frame_);
2042 frame_->setFrameOwnerProperties(frame_owner_properties); 2043 frame_->setFrameOwnerProperties(frame_owner_properties);
2043 } 2044 }
2044 2045
2046 void RenderFrameImpl::OnBlockedLoad() {
2047 frame_->updateForBlockedLoad();
2048 }
2049
2045 void RenderFrameImpl::OnAdvanceFocus(blink::WebFocusType type, 2050 void RenderFrameImpl::OnAdvanceFocus(blink::WebFocusType type,
2046 int32_t source_routing_id) { 2051 int32_t source_routing_id) {
2047 RenderFrameProxy* source_frame = 2052 RenderFrameProxy* source_frame =
2048 RenderFrameProxy::FromRoutingID(source_routing_id); 2053 RenderFrameProxy::FromRoutingID(source_routing_id);
2049 if (!source_frame) 2054 if (!source_frame)
2050 return; 2055 return;
2051 2056
2052 render_view_->webview()->advanceFocusAcrossFrames( 2057 render_view_->webview()->advanceFocusAcrossFrames(
2053 type, source_frame->web_frame(), frame_); 2058 type, source_frame->web_frame(), frame_);
2054 } 2059 }
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after
2779 } 2784 }
2780 2785
2781 void RenderFrameImpl::didChangeFrameOwnerProperties( 2786 void RenderFrameImpl::didChangeFrameOwnerProperties(
2782 blink::WebFrame* child_frame, 2787 blink::WebFrame* child_frame,
2783 const blink::WebFrameOwnerProperties& frame_owner_properties) { 2788 const blink::WebFrameOwnerProperties& frame_owner_properties) {
2784 Send(new FrameHostMsg_DidChangeFrameOwnerProperties( 2789 Send(new FrameHostMsg_DidChangeFrameOwnerProperties(
2785 routing_id_, GetRoutingIdForFrameOrProxy(child_frame), 2790 routing_id_, GetRoutingIdForFrameOrProxy(child_frame),
2786 frame_owner_properties)); 2791 frame_owner_properties));
2787 } 2792 }
2788 2793
2794 void RenderFrameImpl::didBlockLoad() {
2795 Send(new FrameHostMsg_BlockedLoad(routing_id_));
2796 }
2797
2789 void RenderFrameImpl::didMatchCSS( 2798 void RenderFrameImpl::didMatchCSS(
2790 blink::WebLocalFrame* frame, 2799 blink::WebLocalFrame* frame,
2791 const blink::WebVector<blink::WebString>& newly_matching_selectors, 2800 const blink::WebVector<blink::WebString>& newly_matching_selectors,
2792 const blink::WebVector<blink::WebString>& stopped_matching_selectors) { 2801 const blink::WebVector<blink::WebString>& stopped_matching_selectors) {
2793 DCHECK_EQ(frame_, frame); 2802 DCHECK_EQ(frame_, frame);
2794 2803
2795 FOR_EACH_OBSERVER(RenderFrameObserver, observers_, 2804 FOR_EACH_OBSERVER(RenderFrameObserver, observers_,
2796 DidMatchCSS(newly_matching_selectors, 2805 DidMatchCSS(newly_matching_selectors,
2797 stopped_matching_selectors)); 2806 stopped_matching_selectors));
2798 } 2807 }
(...skipping 3303 matching lines...) Expand 10 before | Expand all | Expand 10 after
6102 int match_count, 6111 int match_count,
6103 int ordinal, 6112 int ordinal,
6104 const WebRect& selection_rect, 6113 const WebRect& selection_rect,
6105 bool final_status_update) { 6114 bool final_status_update) {
6106 Send(new FrameHostMsg_Find_Reply(routing_id_, request_id, match_count, 6115 Send(new FrameHostMsg_Find_Reply(routing_id_, request_id, match_count,
6107 selection_rect, ordinal, 6116 selection_rect, ordinal,
6108 final_status_update)); 6117 final_status_update));
6109 } 6118 }
6110 6119
6111 } // namespace content 6120 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_frame_impl.h ('k') | content/test/data/frame-ancestors-none.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698