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

Issue 1726323002: Have Permission{Manager,Service} use Origin. (Closed)

Created:
4 years, 10 months ago by palmer
Modified:
3 years, 10 months ago
CC:
chromium-apps-reviews_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, extensions-reviews_chromium.org, feature-media-reviews_chromium.org, harkness+watch_chromium.org, jam, johnme+watch_chromium.org, mcasas+watch_chromium.org, mlamouri+watch-geolocation_chromium.org, mlamouri+watch-permissions_chromium.org, mlamouri+watch-notifications_chromium.org, mvanouwerkerk+watch_chromium.org, Michael van Ouwerkerk, nasko+codewatch_chromium.org, Peter Beverloo, posciak+watch_chromium.org, toyoshim+midi_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Have Permission{Manager,Service} use Origin. Not GURL. BUG=527149 CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_site_isolation

Patch Set 1 #

Patch Set 2 : Get all targets to build, at least. #

Patch Set 3 : Rebase. #

Patch Set 4 : Fix Blimp interface. #

Total comments: 4

Patch Set 5 : Respond to comments; add some test cases; fix some builds. #

Patch Set 6 : More build fixes; android_webview. #

Patch Set 7 : Clarify and test Origin.empty_. #

Total comments: 11

Patch Set 8 : Respond to comments. #

Patch Set 9 : Rebase. #

Patch Set 10 : Fix some more builds. #

Patch Set 11 : Fix some more builds, but not done yet. #

Patch Set 12 : More build fixes. #

Patch Set 13 : Rebase, fix android webview build. #

Patch Set 14 : Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+793 lines, -645 lines) Patch
M android_webview/browser/aw_permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +10 lines, -10 lines 0 comments Download
M android_webview/browser/aw_permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 15 chunks +66 lines, -70 lines 0 comments Download
M blimp/engine/app/blimp_permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +10 lines, -10 lines 0 comments Download
M blimp/engine/app/blimp_permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +12 lines, -11 lines 0 comments Download
M chrome/browser/background_sync/background_sync_permission_context.h View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/background_sync/background_sync_permission_context.cc View 1 2 3 4 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/background_sync/background_sync_permission_context_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/chromeos/attestation/platform_verification_flow.cc View 1 2 3 4 5 6 7 8 9 2 chunks +3 lines, -4 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context.h View 3 chunks +7 lines, -3 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context.cc View 1 2 3 4 4 chunks +10 lines, -10 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_android.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +14 lines, -11 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_android.cc View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_extensions.h View 2 chunks +5 lines, -2 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_extensions.cc View 3 chunks +5 lines, -4 lines 0 comments Download
M chrome/browser/geolocation/geolocation_permission_context_unittest.cc View 1 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/guest_view/web_view/chrome_web_view_permission_helper_delegate.cc View 2 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/media/media_permission.cc View 1 chunk +5 lines, -4 lines 0 comments Download
M chrome/browser/media/media_stream_device_permission_context.h View 1 chunk +11 lines, -12 lines 0 comments Download
M chrome/browser/media/media_stream_device_permission_context.cc View 4 chunks +16 lines, -15 lines 0 comments Download
M chrome/browser/media/media_stream_device_permission_context_unittest.cc View 1 3 chunks +10 lines, -7 lines 0 comments Download
M chrome/browser/media/midi_permission_context.h View 2 chunks +5 lines, -2 lines 0 comments Download
M chrome/browser/media/midi_permission_context.cc View 2 chunks +8 lines, -6 lines 0 comments Download
M chrome/browser/media/midi_permission_context_unittest.cc View 1 3 chunks +8 lines, -5 lines 0 comments Download
M chrome/browser/media/protected_media_identifier_permission_context.h View 1 2 3 4 3 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/media/protected_media_identifier_permission_context.cc View 1 2 3 4 5 6 7 8 9 10 11 7 chunks +17 lines, -15 lines 0 comments Download
M chrome/browser/notifications/notification_permission_context.h View 3 chunks +10 lines, -7 lines 0 comments Download
M chrome/browser/notifications/notification_permission_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +11 lines, -11 lines 0 comments Download
M chrome/browser/notifications/notification_permission_context_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 8 chunks +23 lines, -18 lines 0 comments Download
M chrome/browser/notifications/platform_notification_service_browsertest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +7 lines, -7 lines 0 comments Download
M chrome/browser/permissions/permission_context_base.h View 1 2 3 4 5 6 7 5 chunks +15 lines, -15 lines 0 comments Download
M chrome/browser/permissions/permission_context_base.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +42 lines, -32 lines 0 comments Download
M chrome/browser/permissions/permission_context_base_unittest.cc View 1 2 9 chunks +18 lines, -13 lines 0 comments Download
M chrome/browser/permissions/permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +15 lines, -11 lines 0 comments Download
M chrome/browser/permissions/permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 8 chunks +28 lines, -24 lines 0 comments Download
M chrome/browser/permissions/permission_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 12 chunks +23 lines, -11 lines 0 comments Download
M chrome/browser/permissions/permission_uma_util.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +3 lines, -2 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context.h View 2 chunks +6 lines, -6 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context.cc View 4 chunks +17 lines, -15 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_permission_context_unittest.cc View 1 2 3 4 5 6 7 8 11 chunks +67 lines, -50 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_service_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +4 lines, -2 lines 0 comments Download
M chrome/browser/push_messaging/push_messaging_service_unittest.cc View 1 2 3 4 5 6 7 9 10 11 12 13 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/storage/durable_storage_permission_context.h View 1 chunk +4 lines, -4 lines 0 comments Download
M chrome/browser/storage/durable_storage_permission_context.cc View 1 2 3 4 5 6 7 8 9 3 chunks +10 lines, -8 lines 0 comments Download
M chromecast/browser/cast_permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +10 lines, -10 lines 0 comments Download
M chromecast/browser/cast_permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +10 lines, -12 lines 0 comments Download
M content/browser/frame_host/render_frame_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +6 lines, -4 lines 0 comments Download
M content/browser/media/cdm/browser_cdm_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -2 lines 0 comments Download
M content/browser/permissions/permission_service_context.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -1 line 0 comments Download
M content/browser/permissions/permission_service_context.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -3 lines 0 comments Download
M content/browser/permissions/permission_service_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 3 chunks +9 lines, -6 lines 0 comments Download
M content/browser/permissions/permission_service_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +35 lines, -47 lines 0 comments Download
M content/browser/push_messaging/push_messaging_message_filter.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +2 lines, -1 line 0 comments Download
M content/public/browser/permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 5 chunks +13 lines, -11 lines 0 comments Download
M content/shell/browser/layout_test/layout_test_message_filter.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -1 line 0 comments Download
M content/shell/browser/layout_test/layout_test_notification_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +7 lines, -6 lines 0 comments Download
M content/shell/browser/layout_test/layout_test_permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 4 chunks +17 lines, -17 lines 0 comments Download
M content/shell/browser/layout_test/layout_test_permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 7 chunks +25 lines, -27 lines 0 comments Download
M content/shell/browser/layout_test/layout_test_push_messaging_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +7 lines, -4 lines 0 comments Download
M content/shell/browser/shell_permission_manager.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +14 lines, -10 lines 0 comments Download
M content/shell/browser/shell_permission_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 5 chunks +11 lines, -12 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/permissions/chromium/resources/test-request.js View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +8 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/permissions/chromium/test-change-event-worker.html View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +3 lines, -0 lines 0 comments Download
M url/origin.h View 1 2 3 4 5 6 3 chunks +8 lines, -0 lines 0 comments Download
M url/origin.cc View 1 2 3 4 5 6 4 chunks +14 lines, -4 lines 0 comments Download
M url/origin_unittest.cc View 1 2 3 4 5 6 7 7 chunks +31 lines, -4 lines 0 comments Download

Messages

Total messages: 52 (17 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/1
4 years, 10 months ago (2016-02-24 01:50:20 UTC) #3
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_android on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_android/builds/26167) cast_shell_linux on ...
4 years, 10 months ago (2016-02-24 02:17:51 UTC) #5
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/40001
4 years, 9 months ago (2016-03-03 01:00:45 UTC) #7
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_android on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_android/builds/30516)
4 years, 9 months ago (2016-03-03 01:14:59 UTC) #9
palmer
Mike, could you please take a look at this and see if you think it's ...
4 years, 9 months ago (2016-03-03 01:32:44 UTC) #11
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/60001
4 years, 9 months ago (2016-03-03 05:39:31 UTC) #13
Mike West
On 2016/03/03 at 05:39:15, Mike West wrote: > The CQ bit was checked by mkwst@chromium.org ...
4 years, 9 months ago (2016-03-03 05:41:08 UTC) #14
Mike West
On 2016/03/03 at 05:41:08, Mike West wrote: > On 2016/03/03 at 05:39:15, Mike West wrote: ...
4 years, 9 months ago (2016-03-03 05:42:39 UTC) #15
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: android_chromium_gn_compile_rel on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_chromium_gn_compile_rel/builds/30975) cast_shell_android on ...
4 years, 9 months ago (2016-03-03 05:58:22 UTC) #17
Mike West
https://codereview.chromium.org/1726323002/diff/60001/chrome/browser/geolocation/geolocation_permission_context.cc File chrome/browser/geolocation/geolocation_permission_context.cc (right): https://codereview.chromium.org/1726323002/diff/60001/chrome/browser/geolocation/geolocation_permission_context.cc#newcode78 chrome/browser/geolocation/geolocation_permission_context.cc:78: GURL(requesting_frame.Serialize()), allowed); Nit: Would you mind adding something like ...
4 years, 9 months ago (2016-03-03 09:20:02 UTC) #18
palmer
https://codereview.chromium.org/1726323002/diff/60001/chrome/browser/geolocation/geolocation_permission_context.cc File chrome/browser/geolocation/geolocation_permission_context.cc (right): https://codereview.chromium.org/1726323002/diff/60001/chrome/browser/geolocation/geolocation_permission_context.cc#newcode78 chrome/browser/geolocation/geolocation_permission_context.cc:78: GURL(requesting_frame.Serialize()), allowed); On 2016/03/03 09:20:02, Mike West wrote: > ...
4 years, 9 months ago (2016-03-03 21:32:57 UTC) #19
palmer
> Actually, another question: should "empty" origins "==" each other? Are they > same-origin with ...
4 years, 9 months ago (2016-03-03 21:33:37 UTC) #20
palmer
This CL looks huge, but it's really about refactoring a widely-used interface from taking a ...
4 years, 9 months ago (2016-03-03 22:11:49 UTC) #22
palmer
Oops, forgot to add sgurun. Additionally, some of the changes are due to "git cl ...
4 years, 9 months ago (2016-03-03 22:13:03 UTC) #24
Avi (use Gerrit)
content LGTM
4 years, 9 months ago (2016-03-03 22:16:27 UTC) #25
sgurun-gerrit only
On 2016/03/03 22:16:27, Avi wrote: > content LGTM lgtm
4 years, 9 months ago (2016-03-03 22:21:01 UTC) #26
palmer
https://codereview.chromium.org/1726323002/diff/120001/url/origin.h File url/origin.h (right): https://codereview.chromium.org/1726323002/diff/120001/url/origin.h#newcode119 url/origin.h:119: bool empty() const { return empty_; } mkwst: Maybe ...
4 years, 9 months ago (2016-03-03 23:18:05 UTC) #27
Mike West
On 2016/03/03 at 23:18:05, palmer wrote: > https://codereview.chromium.org/1726323002/diff/120001/url/origin.h > File url/origin.h (right): > > https://codereview.chromium.org/1726323002/diff/120001/url/origin.h#newcode119 ...
4 years, 9 months ago (2016-03-04 06:02:35 UTC) #28
Mike West
https://codereview.chromium.org/1726323002/diff/120001/url/origin_unittest.cc File url/origin_unittest.cc (right): https://codereview.chromium.org/1726323002/diff/120001/url/origin_unittest.cc#newcode108 url/origin_unittest.cc:108: const char* empties[] = {"yay", ""}; Hrm. Why is ...
4 years, 9 months ago (2016-03-04 06:09:57 UTC) #29
mlamouri (slow - plz ping)
permissions code lgtm. Though, shouldn't bug 515797 be fixed in order for this to land? ...
4 years, 9 months ago (2016-03-05 22:20:18 UTC) #31
jochen (gone - plz use gerrit)
lgtm
4 years, 9 months ago (2016-03-07 12:02:24 UTC) #32
David Trainor- moved to gerrit
blimp/ lgtm
4 years, 9 months ago (2016-03-07 18:55:33 UTC) #33
palmer
https://codereview.chromium.org/1726323002/diff/120001/chrome/browser/permissions/permission_context_base.cc File chrome/browser/permissions/permission_context_base.cc (right): https://codereview.chromium.org/1726323002/diff/120001/chrome/browser/permissions/permission_context_base.cc#newcode63 chrome/browser/permissions/permission_context_base.cc:63: const url::Origin& requesting_frame, On 2016/03/05 22:20:18, Mounir Lamouri wrote: ...
4 years, 9 months ago (2016-03-08 01:20:00 UTC) #34
palmer
mkwst: What do you think of mlamouri's comment in https://codereview.chromium.org/1726323002/#msg31: """Though, shouldn't bug 515797 be ...
4 years, 9 months ago (2016-03-08 01:20:58 UTC) #35
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/160001
4 years, 9 months ago (2016-03-09 20:58:59 UTC) #37
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_android on tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/cast_shell_android/builds/33559)
4 years, 9 months ago (2016-03-09 21:19:11 UTC) #39
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/180001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/180001
4 years, 9 months ago (2016-03-09 22:11:31 UTC) #41
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_linux on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell_linux/builds/127898)
4 years, 9 months ago (2016-03-09 22:29:08 UTC) #43
mlamouri (slow - plz ping)
On 2016/03/08 at 01:20:58, palmer wrote: > mkwst: What do you think of mlamouri's comment ...
4 years, 9 months ago (2016-03-16 11:27:39 UTC) #44
palmer
> > """Though, shouldn't bug 515797 be fixed in order for this to land?""" > ...
4 years, 9 months ago (2016-03-17 01:17:09 UTC) #45
mlamouri (slow - plz ping)
On 2016/03/17 at 01:17:09, palmer wrote: > > > """Though, shouldn't bug 515797 be fixed ...
4 years, 9 months ago (2016-03-21 14:18:24 UTC) #46
palmer
> This is expected. This test is meant to be run with > ./blink/tools/run_layout_tests.py (which ...
4 years, 8 months ago (2016-03-28 23:00:34 UTC) #47
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1726323002/260001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1726323002/260001
4 years, 8 months ago (2016-03-28 23:02:32 UTC) #49
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: cast_shell_linux on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/cast_shell_linux/builds/135643)
4 years, 8 months ago (2016-03-28 23:19:22 UTC) #51
mlamouri (slow - plz ping)
4 years, 8 months ago (2016-03-31 21:41:12 UTC) #52
On 2016/03/28 at 23:00:34, palmer wrote:
> > This is expected. This test is meant to be run with
> > ./blink/tools/run_layout_tests.py (which will start an HTTP server). You can
run
> > it by creating the HTTP server yourself. If you don't, you will have a
file://
> > location but it is expected to have some real non-local origin. The test
should
> > be able to handle localhost:xxxx.
> 
> Thanks for the clue. :) But, I'm not sure I understand, then. Don't the
trybots run the tests with /blink/tools/run_layout_tests.py and using an HTTP
server?

Yes, they do that. Though, in your comment you said you do
`./out/Debug/content_shell --run-layout-test --no-sandbox
http/tests/permissions/chromium/test-change-event-worker.html` which isn't
running an HTTP server, right?

Powered by Google App Engine
This is Rietveld 408576698