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

Issue 2908593002: Fix Docs links from Files app on ChromeOS not working with PlzNavigate. (Closed)

Created:
3 years, 7 months ago by jam
Modified:
3 years, 7 months ago
Reviewers:
Charlie Reis, nasko
CC:
chromium-reviews, loading-reviews_chromium.org, darin-cc_chromium.org, Randy Smith (Not in Mondays), mmenke, arthursonzogni
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix Docs links from Files app on ChromeOS not working with PlzNavigate. The cause was that there was a redirect from externalfile scheme to https. The PlzNavigate code chose the right ending process based on the final URL. However when the renderer made a request for the stream URL, it does attach the original URL (pre-redirect) along. ResourceDispatcherHostImpl::ShouldServiceRequest was incorrectly aborting the URL because that process rightly does not have access to the externalfile scheme. The fix is to skip the ChildProcessSecurityPolicy::CanRequestURL check in ShouldServiceRequest for the PlzNavigate stream request. The browser already picked the right process, and the stream URL is unguessable. The change also skips most of ContinuePendingBeginRequest() and CreateResourceHandler() for PlzNavigate stream requests to minimize the risk that they contain code that could be exploited. BUG=717644 Review-Url: https://codereview.chromium.org/2908593002 Cr-Commit-Position: refs/heads/master@{#475097} Committed: https://chromium.googlesource.com/chromium/src/+/ecb25eb8968a45120ee434af2d3da30baebc6b63

Patch Set 1 #

Total comments: 5

Patch Set 2 : skip most codepaths under PlzNavigate #

Patch Set 3 : call most of ShouldServiceRequest #

Total comments: 6

Patch Set 4 : review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+219 lines, -182 lines) Patch
M content/browser/loader/resource_dispatcher_host_impl.h View 1 1 chunk +7 lines, -0 lines 0 comments Download
M content/browser/loader/resource_dispatcher_host_impl.cc View 1 2 3 8 chunks +212 lines, -182 lines 0 comments Download

Messages

Total messages: 36 (20 generated)
jam
pta, working on a test in meantime
3 years, 7 months ago (2017-05-25 20:57:03 UTC) #4
jam
+Charlie as well, since this is a replacement fix for https://codereview.chromium.org/2897963003/
3 years, 7 months ago (2017-05-25 21:00:57 UTC) #7
Charlie Reis
Thanks for looking into this! One concern below. https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (right): https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 content/browser/loader/resource_dispatcher_host_impl.cc:1155: (!is_navigation_stream_request ...
3 years, 7 months ago (2017-05-25 21:28:53 UTC) #8
jam
https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (right): https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 content/browser/loader/resource_dispatcher_host_impl.cc:1155: (!is_navigation_stream_request && On 2017/05/25 21:28:53, Charlie Reis (overloaded) wrote: ...
3 years, 7 months ago (2017-05-25 21:45:17 UTC) #9
jam
https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (right): https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 content/browser/loader/resource_dispatcher_host_impl.cc:1155: (!is_navigation_stream_request && also: once we use mojo for loading, ...
3 years, 7 months ago (2017-05-25 21:47:57 UTC) #10
jam
https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (right): https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 content/browser/loader/resource_dispatcher_host_impl.cc:1155: (!is_navigation_stream_request && On 2017/05/25 21:28:53, Charlie Reis (overloaded) wrote: ...
3 years, 7 months ago (2017-05-25 22:00:41 UTC) #11
nasko
On 2017/05/25 22:00:41, jam wrote: > https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc > File content/browser/loader/resource_dispatcher_host_impl.cc (right): > > https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 > ...
3 years, 7 months ago (2017-05-25 22:03:36 UTC) #12
jam
On 2017/05/25 22:03:36, nasko wrote: > On 2017/05/25 22:00:41, jam wrote: > > > https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc ...
3 years, 7 months ago (2017-05-25 22:46:07 UTC) #15
Charlie Reis
https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (right): https://codereview.chromium.org/2908593002/diff/1/content/browser/loader/resource_dispatcher_host_impl.cc#newcode1155 content/browser/loader/resource_dispatcher_host_impl.cc:1155: (!is_navigation_stream_request && On 2017/05/25 22:00:41, jam wrote: > On ...
3 years, 7 months ago (2017-05-25 23:11:01 UTC) #16
Charlie Reis
On 2017/05/25 22:46:07, jam wrote: > On 2017/05/25 22:03:36, nasko wrote: > > On 2017/05/25 ...
3 years, 7 months ago (2017-05-25 23:12:18 UTC) #17
jam
On 2017/05/25 23:11:01, Charlie Reis (OOO until 5-30) wrote: > I agree with you now ...
3 years, 7 months ago (2017-05-26 02:05:04 UTC) #20
nasko
Couple of notes that make the code a bit easier to follow, but overall I ...
3 years, 7 months ago (2017-05-26 18:18:14 UTC) #26
jam
https://codereview.chromium.org/2908593002/diff/40001/content/browser/loader/resource_dispatcher_host_impl.cc File content/browser/loader/resource_dispatcher_host_impl.cc (left): https://codereview.chromium.org/2908593002/diff/40001/content/browser/loader/resource_dispatcher_host_impl.cc#oldcode1113 content/browser/loader/resource_dispatcher_host_impl.cc:1113: } On 2017/05/26 18:18:14, nasko wrote: > Why not ...
3 years, 7 months ago (2017-05-26 18:27:05 UTC) #29
nasko
LGTM
3 years, 7 months ago (2017-05-26 19:39:30 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2908593002/60001
3 years, 7 months ago (2017-05-26 19:44:37 UTC) #33
commit-bot: I haz the power
3 years, 7 months ago (2017-05-26 20:06:32 UTC) #36
Message was sent while issue was closed.
Committed patchset #4 (id:60001) as
https://chromium.googlesource.com/chromium/src/+/ecb25eb8968a45120ee434af2d3d...

Powered by Google App Engine
This is Rietveld 408576698