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

Issue 2856653004: Require a process ID when looking up RFHs by FrameTreeNode ID. (Closed)

Created:
3 years, 7 months ago by Charlie Reis
Modified:
3 years, 7 months ago
CC:
chromium-apps-reviews_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, dmazzoni, extensions-reviews_chromium.org, grt+watch_chromium.org, jam, Ɓukasz Anforowicz, nasko+codewatch_chromium.org, site-isolation-reviews_chromium.org, subresource-filter-reviews_chromium.org, timvolodine, vakh+watch_chromium.org, lazyboy
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Require a process ID when looking up RFHs by FrameTreeNode ID. This helps avoid security bugs where callers store a FrameTreeNode ID and later assume it is for the same RenderFrameHost. However, a cross-process navigation may have taken place, leading to a higher or lower privileged page. Because extension APIs use the old approach, the previous API is left as an unsafe option, with comments encouraging callers to avoid it. BUG=715541 TEST=No behavior change. CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_site_isolation Review-Url: https://codereview.chromium.org/2856653004 Cr-Commit-Position: refs/heads/master@{#469410} Committed: https://chromium.googlesource.com/chromium/src/+/f71a263681dc50097672cc55e0204c7b0e789a48

Patch Set 1 #

Total comments: 1

Patch Set 2 : Add comment. #

Total comments: 4

Patch Set 3 : Remove GetParentFtnId. #

Total comments: 2

Patch Set 4 : Update comment. #

Total comments: 4

Patch Set 5 : Fix bug #

Patch Set 6 : Rebase #

Patch Set 7 : Simplify ExtNavThrottle #

Total comments: 2

Messages

Total messages: 40 (26 generated)
Charlie Reis
Nick, can you take a look? https://codereview.chromium.org/2856653004/diff/1/chrome/browser/safe_browsing/safe_browsing_navigation_observer.cc File chrome/browser/safe_browsing/safe_browsing_navigation_observer.cc (right): https://codereview.chromium.org/2856653004/diff/1/chrome/browser/safe_browsing/safe_browsing_navigation_observer.cc#newcode148 chrome/browser/safe_browsing/safe_browsing_navigation_observer.cc:148: navigation_handle->GetStartingSiteInstance()->GetProcess()->GetID(); This is ...
3 years, 7 months ago (2017-05-01 21:56:59 UTC) #5
ncarter (slow)
https://codereview.chromium.org/2856653004/diff/20001/content/public/browser/navigation_handle.h File content/public/browser/navigation_handle.h (right): https://codereview.chromium.org/2856653004/diff/20001/content/public/browser/navigation_handle.h#newcode86 content/public/browser/navigation_handle.h:86: // taking place in the main frame, the value ...
3 years, 7 months ago (2017-05-01 22:15:32 UTC) #6
Charlie Reis
https://codereview.chromium.org/2856653004/diff/20001/content/public/browser/navigation_handle.h File content/public/browser/navigation_handle.h (right): https://codereview.chromium.org/2856653004/diff/20001/content/public/browser/navigation_handle.h#newcode86 content/public/browser/navigation_handle.h:86: // taking place in the main frame, the value ...
3 years, 7 months ago (2017-05-01 22:36:51 UTC) #9
ncarter (slow)
lgtm
3 years, 7 months ago (2017-05-01 22:51:17 UTC) #10
dmazzoni
https://codereview.chromium.org/2856653004/diff/40001/content/public/browser/web_contents.h File content/public/browser/web_contents.h (right): https://codereview.chromium.org/2856653004/diff/40001/content/public/browser/web_contents.h#newcode248 content/public/browser/web_contents.h:248: // part of this tab. Returns nullptr if |process_id| ...
3 years, 7 months ago (2017-05-01 22:56:38 UTC) #12
Charlie Reis
Thanks! clamy@: Can you review the NavigationHandle changes, to double check that you're ok with ...
3 years, 7 months ago (2017-05-01 23:12:36 UTC) #16
Jialiu Lin
lgtm for c/b/safe_browsing Thanks!
3 years, 7 months ago (2017-05-01 23:14:35 UTC) #17
Devlin
https://codereview.chromium.org/2856653004/diff/60001/content/browser/web_contents/web_contents_impl.cc File content/browser/web_contents/web_contents_impl.cc (right): https://codereview.chromium.org/2856653004/diff/60001/content/browser/web_contents/web_contents_impl.cc#newcode926 content/browser/web_contents/web_contents_impl.cc:926: if (!frame || current_frame_host->GetProcess()->GetID() != process_id) If !frame is ...
3 years, 7 months ago (2017-05-02 02:04:29 UTC) #20
Charlie Harrison
subresource_filter LGTM thanks for the nicer nav handle API.
3 years, 7 months ago (2017-05-02 02:45:50 UTC) #22
Charlie Reis
[+ekaramad, CC lazyboy] Heh, I waited just long enough to update this to hit a ...
3 years, 7 months ago (2017-05-04 16:29:58 UTC) #32
Devlin
lgtm
3 years, 7 months ago (2017-05-04 17:56:34 UTC) #33
EhsanK
Thanks Charlie and sorry for the random clash. LGTM. https://codereview.chromium.org/2856653004/diff/120001/extensions/browser/extension_navigation_throttle.cc File extensions/browser/extension_navigation_throttle.cc (right): https://codereview.chromium.org/2856653004/diff/120001/extensions/browser/extension_navigation_throttle.cc#newcode111 extensions/browser/extension_navigation_throttle.cc:111: ...
3 years, 7 months ago (2017-05-04 18:01:39 UTC) #34
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/2856653004/120001
3 years, 7 months ago (2017-05-04 18:57:19 UTC) #37
commit-bot: I haz the power
3 years, 7 months ago (2017-05-04 19:04:08 UTC) #40
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/chromium/src/+/f71a263681dc50097672cc55e020...

Powered by Google App Engine
This is Rietveld 408576698