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

Issue 23856006: <webview>: Do not show blocked_by_client error page for guest. (Closed)

Created:
7 years, 3 months ago by lazyboy
Modified:
7 years, 3 months ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

<webview>: Do not show blocked_by_client error page for guest. When a request to load a top level frame inside webview is cancelled by using <webview>'s WebRequest API, by default we load "This webpage is blocked by an extension" error page. This CL avoids loading error page's html in guest render view. We already fire loadabort event in this case. BUG=284741 Test=With webrequest API, a webview containing: <a href="http://foo">Foo</a> When clicked on the link, if embedder wants to prevent navigating the <webview> to foo, does so using webRequest API to cancel: <webview>.request.onBeforeRequest.addListener(function(details) { if (details.type == 'main_frame' && details.url == 'http://foo' { window.open('...'); return {cancel: true}; } return {cancel: 'false'}; }, {urls: ['<all_urls>']}, ['blocking']); The "return {cancel:true}" won't load the mentioned error page anymore in the webview. Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=223769

Patch Set 1 #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+15 lines, -1 line) Patch
M content/browser/browser_plugin/browser_plugin_guest.cc View 1 chunk +2 lines, -0 lines 0 comments Download
M content/common/view_messages.h View 1 chunk +1 line, -0 lines 0 comments Download
M content/public/common/renderer_preferences.h View 1 chunk +4 lines, -0 lines 0 comments Download
M content/public/common/renderer_preferences.cc View 1 chunk +2 lines, -1 line 0 comments Download
M content/renderer/render_view_impl.cc View 1 chunk +6 lines, -0 lines 3 comments Download

Messages

Total messages: 14 (0 generated)
lazyboy
Hi Charlie, Can you take a look at the starter approach? Thanks.
7 years, 3 months ago (2013-09-03 22:53:55 UTC) #1
Charlie Reis
https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc File content/renderer/render_view_impl.cc (right): https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc#newcode3672 content/renderer/render_view_impl.cc:3672: // 'replace' load. This is necessary to avoid messing ...
7 years, 3 months ago (2013-09-03 23:14:31 UTC) #2
lazyboy
On 2013/09/03 23:14:31, creis wrote: > https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc > File content/renderer/render_view_impl.cc (right): > > https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc#newcode3672 > ...
7 years, 3 months ago (2013-09-04 20:55:37 UTC) #3
lazyboy
On 2013/09/04 20:55:37, lazyboy wrote: > On 2013/09/03 23:14:31, creis wrote: > > > https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc ...
7 years, 3 months ago (2013-09-13 20:09:25 UTC) #4
Fady Samuel
https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc File content/renderer/render_view_impl.cc (right): https://chromiumcodereview.appspot.com/23856006/diff/1/content/renderer/render_view_impl.cc#newcode3672 content/renderer/render_view_impl.cc:3672: // 'replace' load. This is necessary to avoid messing ...
7 years, 3 months ago (2013-09-13 20:12:22 UTC) #5
Charlie Reis
I feel like it's worth confirming this is a sane behavior with someone more familiar ...
7 years, 3 months ago (2013-09-13 21:44:56 UTC) #6
lazyboy
On 2013/09/13 21:44:56, creis wrote: > I feel like it's worth confirming this is a ...
7 years, 3 months ago (2013-09-13 22:11:18 UTC) #7
lazyboy
On 2013/09/13 22:11:18, lazyboy wrote: > On 2013/09/13 21:44:56, creis wrote: > > I feel ...
7 years, 3 months ago (2013-09-13 22:50:07 UTC) #8
Matt Perry
LGTM. What do you display instead? A blank page?
7 years, 3 months ago (2013-09-16 18:53:01 UTC) #9
lazyboy
On 2013/09/16 18:53:01, Matt Perry wrote: > LGTM. > > What do you display instead? ...
7 years, 3 months ago (2013-09-16 18:56:25 UTC) #10
lazyboy
+cdn for Security review: content/public/common/view_messages.h
7 years, 3 months ago (2013-09-16 23:00:20 UTC) #11
Cris Neckar
IPC changes LGTM
7 years, 3 months ago (2013-09-17 18:06:16 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/lazyboy@chromium.org/23856006/1
7 years, 3 months ago (2013-09-17 19:20:57 UTC) #13
commit-bot: I haz the power
7 years, 3 months ago (2013-09-18 02:11:03 UTC) #14
Message was sent while issue was closed.
Change committed as 223769

Powered by Google App Engine
This is Rietveld 408576698