Chromium Code Reviews
Help | Chromium Project | Gerrit Changes | Sign in
(1)

Issue 1301653005: Setup for moving getUserMedia to secure origins only (Closed)

Created:
3 years, 7 months ago by jww
Modified:
3 years, 7 months ago
CC:
chromium-reviews, extensions-reviews_chromium.org, posciak+watch_chromium.org, mcasas+watch_chromium.org, feature-media-reviews_chromium.org, chromium-apps-reviews_chromium.org, wjia+watch_chromium.org, tommi (sloooow) - chröme, lgarron
Base URL:
https://chromium.googlesource.com/chromium/src@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Setup for moving getUserMedia to secure origins only This makes two notable changes: * Removes the browser tests that verify that the getUserMedia permission is not "sticky" on insecure origins. * Moves the addition of the chrome-extension: and chrome-extension-resource: schemes to extensions::Dispatcher. The former is necessary because once getUserMedia is removed from insecure origins, the browser test will (correctly) fail. Thus this is part of a two sided patch. The later is necessary because extension browser tests that use getUserMedia will start failing once the change is made, because the tests use ShellContentRendererClient, which doesn't currently treat chrome-extension: schemes as secure, so getUserMedia will be disallowed by the renderer. By marking the scheme as secure in extensions::Dispatcher instead of in ChromeContentRendererClient::RenderThreadStarted, the schemes will be marked as secure in ShellContentRendererClient as well, so getUserMedia will be allowed in the browser tests. BUG=520765 Committed: https://crrev.com/8440052c7882f61cfde793f687e72717c85e0d8f Cr-Commit-Position: refs/heads/master@{#344635}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Move secure extension scheme registration to Dispatcher #

Patch Set 3 : Comment update and code simplification #

Total comments: 4

Patch Set 4 : Nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+30 lines, -85 lines) Patch
M chrome/browser/media/chrome_media_stream_infobar_browsertest.cc View 1 2 3 chunks +3 lines, -61 lines 0 comments Download
M chrome/renderer/chrome_content_renderer_client.cc View 1 2 3 1 chunk +3 lines, -21 lines 0 comments Download
M extensions/renderer/dispatcher.cc View 1 2 1 chunk +24 lines, -0 lines 0 comments Download
M extensions/shell/renderer/shell_content_renderer_client.cc View 1 2 3 1 chunk +0 lines, -3 lines 0 comments Download

Messages

Total messages: 21 (7 generated)
jww
rdevlin.cronin@chromium.org: Please review changes in extensions/shell/renderer/shell_content_renderer_client.cc ddorwin@chromium.org: Please review changes in chrome/browser/media/chrome_media_stream_infobar_browsertest.cc For reference, here ...
3 years, 7 months ago (2015-08-20 16:30:02 UTC) #2
Devlin
extensions lgtm with a suggestion. https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc File extensions/shell/renderer/shell_content_renderer_client.cc (right): https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc#newcode66 extensions/shell/renderer/shell_content_renderer_client.cc:66: // chrome-extensions: and chrome-extensions-resource: ...
3 years, 7 months ago (2015-08-20 16:37:20 UTC) #3
jww
https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc File extensions/shell/renderer/shell_content_renderer_client.cc (right): https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc#newcode66 extensions/shell/renderer/shell_content_renderer_client.cc:66: // chrome-extensions: and chrome-extensions-resource: schemes should be On 2015/08/20 ...
3 years, 7 months ago (2015-08-20 16:50:35 UTC) #4
ddorwin
LGTM. +tommi FYI
3 years, 7 months ago (2015-08-20 16:56:11 UTC) #5
ddorwin
https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc File extensions/shell/renderer/shell_content_renderer_client.cc (right): https://codereview.chromium.org/1301653005/diff/1/extensions/shell/renderer/shell_content_renderer_client.cc#newcode66 extensions/shell/renderer/shell_content_renderer_client.cc:66: // chrome-extensions: and chrome-extensions-resource: schemes should be On 2015/08/20 ...
3 years, 7 months ago (2015-08-20 16:57:20 UTC) #6
tommi (sloooow) - chröme
https://codereview.chromium.org/1301653005/diff/1/chrome/browser/media/chrome_media_stream_infobar_browsertest.cc File chrome/browser/media/chrome_media_stream_infobar_browsertest.cc (left): https://codereview.chromium.org/1301653005/diff/1/chrome/browser/media/chrome_media_stream_infobar_browsertest.cc#oldcode73 chrome/browser/media/chrome_media_stream_infobar_browsertest.cc:73: use_secure_origin_for_test_page_ = false; looks like this variable isn't needed ...
3 years, 7 months ago (2015-08-20 17:14:25 UTC) #8
jww
thestig@chromium.org, can you take a look at chrome/renderer/chrome_content_renderer_client.cc? Note that this just moves the code ...
3 years, 7 months ago (2015-08-20 18:26:07 UTC) #10
Devlin
(extensions still lgtm) https://codereview.chromium.org/1301653005/diff/40001/chrome/renderer/chrome_content_renderer_client.cc File chrome/renderer/chrome_content_renderer_client.cc (right): https://codereview.chromium.org/1301653005/diff/40001/chrome/renderer/chrome_content_renderer_client.cc#newcode502 chrome/renderer/chrome_content_renderer_client.cc:502: // care of in extension::Dispatcher. nitty ...
3 years, 7 months ago (2015-08-20 18:29:34 UTC) #11
tommi (sloooow) - chröme
Thanks! lgtm.
3 years, 7 months ago (2015-08-20 18:36:53 UTC) #12
Lei Zhang
lgtm
3 years, 7 months ago (2015-08-20 20:43:01 UTC) #13
jww
lgarron@, FYI https://codereview.chromium.org/1301653005/diff/40001/chrome/renderer/chrome_content_renderer_client.cc File chrome/renderer/chrome_content_renderer_client.cc (right): https://codereview.chromium.org/1301653005/diff/40001/chrome/renderer/chrome_content_renderer_client.cc#newcode502 chrome/renderer/chrome_content_renderer_client.cc:502: // care of in extension::Dispatcher. On 2015/08/20 ...
3 years, 7 months ago (2015-08-20 22:59:03 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1301653005/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1301653005/60001
3 years, 7 months ago (2015-08-20 23:04:15 UTC) #19
commit-bot: I haz the power
Committed patchset #4 (id:60001)
3 years, 7 months ago (2015-08-21 01:05:56 UTC) #20
commit-bot: I haz the power
3 years, 7 months ago (2015-08-21 01:06:29 UTC) #21
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/8440052c7882f61cfde793f687e72717c85e0d8f
Cr-Commit-Position: refs/heads/master@{#344635}

Powered by Google App Engine
This is Rietveld 408576698