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

Issue 1803973002: Content Settings: Add RevocationObserver to measure when permissions are revoked (Closed)

Created:
4 years, 9 months ago by tsergeant
Modified:
4 years, 8 months ago
CC:
chrome-apps-syd-reviews_chromium.org, chromium-reviews, markusheintz_, msramek+watch_chromium.org, raymes+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Content Settings: Add method to measure when permissions are revoked This CL adds a new method which wraps SetContentSettingDefaultScope to determine when a permission is revoked. This allows us to collect revocation metrics from Android Site Settings and desktop Page Action bubbles. BUG=469221 Committed: https://crrev.com/aa3dab6655aa3e927fb381691824f471172ce479 Cr-Commit-Position: refs/heads/master@{#385132}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : Add test #

Total comments: 13

Patch Set 4 : Review comments #

Total comments: 2

Patch Set 5 : Review comments #

Total comments: 1

Patch Set 6 : Rewrite patch in permissions layer #

Total comments: 8

Patch Set 7 : Review comments #

Patch Set 8 : Update rappor.xml #

Total comments: 2

Patch Set 9 : Remove bool return #

Patch Set 10 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+144 lines, -35 lines) Patch
M chrome/browser/android/preferences/website_preference_bridge.cc View 1 2 3 4 5 6 7 8 9 2 chunks +4 lines, -3 lines 0 comments Download
M chrome/browser/permissions/permission_uma_util.h View 1 2 3 4 5 6 1 chunk +16 lines, -0 lines 0 comments Download
M chrome/browser/permissions/permission_uma_util.cc View 1 2 3 4 5 6 7 8 1 chunk +0 lines, -16 lines 0 comments Download
M chrome/browser/permissions/permission_util.h View 1 2 3 4 5 6 7 8 2 chunks +21 lines, -0 lines 0 comments Download
M chrome/browser/permissions/permission_util.cc View 1 2 3 4 5 6 7 8 2 chunks +30 lines, -0 lines 0 comments Download
A chrome/browser/permissions/permission_util_unittest.cc View 1 2 3 4 5 6 7 8 1 chunk +54 lines, -0 lines 0 comments Download
M chrome/browser/ui/content_settings/content_setting_bubble_model.cc View 1 2 3 4 5 6 5 chunks +8 lines, -12 lines 0 comments Download
M chrome/browser/ui/website_settings/website_settings.cc View 1 2 3 4 5 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M tools/metrics/rappor/rappor.xml View 1 2 3 4 5 6 7 8 4 chunks +8 lines, -4 lines 0 comments Download

Depends on Patchset:

Messages

Total messages: 41 (12 generated)
tsergeant
Can you please take an initial look? I still have the problem where PermissionManager does ...
4 years, 9 months ago (2016-03-15 23:05:53 UTC) #4
mlamouri (slow - plz ping)
That sounds like a lot of code added just to do the UMA on the ...
4 years, 9 months ago (2016-03-16 11:07:04 UTC) #6
tsergeant
On 2016/03/16 11:07:04, Mounir Lamouri wrote: > That sounds like a lot of code added ...
4 years, 9 months ago (2016-03-16 22:46:29 UTC) #7
raymes
https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/permissions/permission_manager.cc File chrome/browser/permissions/permission_manager.cc (right): https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/permissions/permission_manager.cc#newcode445 chrome/browser/permissions/permission_manager.cc:445: if (PermissionUtil::GetPermissionType(content_type, &permission_type)) { nit: no {} https://codereview.chromium.org/1803973002/diff/40001/components/content_settings/core/browser/content_settings_observer.h File ...
4 years, 9 months ago (2016-03-17 02:05:43 UTC) #8
kcarattini
https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/content_settings/host_content_settings_map_unittest.cc File chrome/browser/content_settings/host_content_settings_map_unittest.cc (right): https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/content_settings/host_content_settings_map_unittest.cc#newcode1110 chrome/browser/content_settings/host_content_settings_map_unittest.cc:1110: // Allow->Default triggers a revocation when default is 'ask'. ...
4 years, 9 months ago (2016-03-17 02:51:22 UTC) #10
tsergeant
https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/content_settings/host_content_settings_map_unittest.cc File chrome/browser/content_settings/host_content_settings_map_unittest.cc (right): https://codereview.chromium.org/1803973002/diff/40001/chrome/browser/content_settings/host_content_settings_map_unittest.cc#newcode1110 chrome/browser/content_settings/host_content_settings_map_unittest.cc:1110: // Allow->Default triggers a revocation when default is 'ask'. ...
4 years, 9 months ago (2016-03-17 06:25:40 UTC) #11
raymes
https://codereview.chromium.org/1803973002/diff/60001/components/content_settings/core/browser/content_settings_observer.h File components/content_settings/core/browser/content_settings_observer.h (right): https://codereview.chromium.org/1803973002/diff/60001/components/content_settings/core/browser/content_settings_observer.h#newcode23 components/content_settings/core/browser/content_settings_observer.h:23: virtual void OnContentSettingRevoked( nit: perhaps add a comment about ...
4 years, 9 months ago (2016-03-21 01:52:57 UTC) #13
tsergeant
Bernhard, can you please take a look? This is something that would fit better higher ...
4 years, 9 months ago (2016-03-21 03:38:38 UTC) #14
raymes
lgtm (but as discussed we'll make sure bauerb@ is ok with this)
4 years, 9 months ago (2016-03-21 06:14:02 UTC) #15
kcarattini
lgtm
4 years, 9 months ago (2016-03-21 10:40:27 UTC) #16
Bernhard Bauer
I find this a bit... odd. For one, tracking "revocations" implies that a permission is ...
4 years, 9 months ago (2016-03-21 11:56:31 UTC) #17
tsergeant
Hi Bernhard, thanks for your feedback. I've uploaded a new patch which takes a different ...
4 years, 9 months ago (2016-03-22 05:43:16 UTC) #18
Bernhard Bauer
That's much nicer, thanks! https://codereview.chromium.org/1803973002/diff/100001/chrome/browser/permissions/permission_util.cc File chrome/browser/permissions/permission_util.cc (right): https://codereview.chromium.org/1803973002/diff/100001/chrome/browser/permissions/permission_util.cc#newcode13 chrome/browser/permissions/permission_util.cc:13: Nit: This empty line is ...
4 years, 9 months ago (2016-03-22 10:13:30 UTC) #20
tsergeant
https://codereview.chromium.org/1803973002/diff/100001/chrome/browser/permissions/permission_util.cc File chrome/browser/permissions/permission_util.cc (right): https://codereview.chromium.org/1803973002/diff/100001/chrome/browser/permissions/permission_util.cc#newcode13 chrome/browser/permissions/permission_util.cc:13: On 2016/03/22 10:13:29, Bernhard Bauer wrote: > Nit: This ...
4 years, 9 months ago (2016-03-22 23:55:20 UTC) #21
tsergeant
Ping bauerb/mlamouri: Can you please take another look?
4 years, 8 months ago (2016-03-29 00:08:30 UTC) #22
Bernhard Bauer
LGTM, thanks!
4 years, 8 months ago (2016-03-29 08:25:38 UTC) #23
tsergeant
+felt@ for c/b/permissions/ and the comment in c/b/ui/website_settings/website_settings.cc.
4 years, 8 months ago (2016-03-30 23:49:22 UTC) #24
tsergeant
...actually +felt@ this time (for c/b/permissions/ and the comment in c/b/ui/website_settings/website_settings.cc) Thanks!
4 years, 8 months ago (2016-03-30 23:50:30 UTC) #26
mlamouri (slow - plz ping)
lgtm
4 years, 8 months ago (2016-03-31 10:10:15 UTC) #27
mlamouri (slow - plz ping)
Sorry for the delay, I was offline for the last few days.
4 years, 8 months ago (2016-03-31 10:10:34 UTC) #28
tsergeant
On 2016/03/31 10:10:34, Mounir Lamouri wrote: > Sorry for the delay, I was offline for ...
4 years, 8 months ago (2016-03-31 22:24:05 UTC) #29
tsergeant
+holte@ for rappor.xml
4 years, 8 months ago (2016-03-31 22:43:10 UTC) #31
Steven Holte
On 2016/03/31 22:43:10, tsergeant wrote: > +holte@ for rappor.xml lgtm
4 years, 8 months ago (2016-04-01 18:26:40 UTC) #32
felt
just a nit/question https://codereview.chromium.org/1803973002/diff/140001/chrome/browser/permissions/permission_util.h File chrome/browser/permissions/permission_util.h (right): https://codereview.chromium.org/1803973002/diff/140001/chrome/browser/permissions/permission_util.h#newcode44 chrome/browser/permissions/permission_util.h:44: // crbug.com/469221. Seems a little weird ...
4 years, 8 months ago (2016-04-04 13:20:27 UTC) #33
tsergeant
https://codereview.chromium.org/1803973002/diff/140001/chrome/browser/permissions/permission_util.h File chrome/browser/permissions/permission_util.h (right): https://codereview.chromium.org/1803973002/diff/140001/chrome/browser/permissions/permission_util.h#newcode44 chrome/browser/permissions/permission_util.h:44: // crbug.com/469221. On 2016/04/04 13:20:27, felt wrote: > Seems ...
4 years, 8 months ago (2016-04-04 23:48:29 UTC) #34
felt
lgtm
4 years, 8 months ago (2016-04-05 01:15:23 UTC) #35
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1803973002/180001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1803973002/180001
4 years, 8 months ago (2016-04-05 07:42:51 UTC) #38
commit-bot: I haz the power
Committed patchset #10 (id:180001)
4 years, 8 months ago (2016-04-05 08:14:21 UTC) #39
commit-bot: I haz the power
4 years, 8 months ago (2016-04-05 08:15:57 UTC) #41
Message was sent while issue was closed.
Patchset 10 (id:??) landed as
https://crrev.com/aa3dab6655aa3e927fb381691824f471172ce479
Cr-Commit-Position: refs/heads/master@{#385132}

Powered by Google App Engine
This is Rietveld 408576698