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

Issue 2054773002: Replace the WAS_INSTALLED_BY_CUSTODIAN creation flag with a pref (Closed)

Created:
4 years, 6 months ago by mamir
Modified:
4 years, 6 months ago
CC:
chromium-reviews, chromium-apps-reviews_chromium.org, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Replace the WAS_INSTALLED_BY_CUSTODIAN creation flag with a pref Before this CL: If a custodian-installed extension was already installed in the browser before the child signs in, the "WasInstalledByCustodian" flag is stored in Sync was ignored and the default value (false) is used giving the child the ability to uninstall the extension for example. After this CL: The creation flag has been replaced with a pref which is updated properly upon receiving Sync data. BUG=619526 Committed: https://crrev.com/192d78833ff9297c754f59f20cb4e590d693a7c2 Cr-Commit-Position: refs/heads/master@{#401318}

Patch Set 1 #

Patch Set 2 : Fix the bug of delegated installs for pre-existing extensions #

Total comments: 21

Patch Set 3 : Response to code review by treib@ #

Total comments: 8

Patch Set 4 : Response to code review by treib@ #

Total comments: 16

Patch Set 5 : Response to code review #

Patch Set 6 : Response to code review by Devlin #

Total comments: 5

Patch Set 7 : Response to code review by Devlin #

Patch Set 8 : Remove extension check from util::SetWasInstalledByCustodian #

Patch Set 9 : Removing the creation flag completely #

Patch Set 10 : Commenting out WAS_INSTALLED_BY_CUSTODIAN flag #

Total comments: 12

Patch Set 11 : Response to code review by Marc #

Total comments: 10

Patch Set 12 : Response to code review by Marc #

Total comments: 12

Patch Set 13 : Response to code review by Marc #

Patch Set 14 : reload if installed_by_custodian becomes false. #

Total comments: 12

Patch Set 15 : Response to code review by Marc #

Total comments: 11

Patch Set 16 : Response to code review by Devlin. #

Patch Set 17 : rebase #

Patch Set 18 : Fixing the build #

Unified diffs Side-by-side diffs Delta from patch set Stats (+267 lines, -125 lines) Patch
M chrome/browser/extensions/extension_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 3 chunks +1 line, -5 lines 0 comments Download
M chrome/browser/extensions/extension_service_sync_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 12 chunks +102 lines, -14 lines 0 comments Download
M chrome/browser/extensions/extension_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 12 chunks +9 lines, -19 lines 0 comments Download
M chrome/browser/extensions/extension_sync_data.h View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/extensions/extension_sync_data.cc View 1 2 3 4 5 6 7 8 3 chunks +6 lines, -3 lines 0 comments Download
M chrome/browser/extensions/extension_sync_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 3 chunks +10 lines, -3 lines 0 comments Download
M chrome/browser/extensions/extension_util.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +15 lines, -1 line 0 comments Download
M chrome/browser/extensions/extension_util.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 3 chunks +50 lines, -2 lines 0 comments Download
M chrome/browser/extensions/pending_extension_info.h View 1 2 3 4 3 chunks +0 lines, -3 lines 0 comments Download
M chrome/browser/extensions/pending_extension_info.cc View 1 2 3 4 3 chunks +0 lines, -3 lines 0 comments Download
M chrome/browser/extensions/pending_extension_manager.h View 1 2 3 4 2 chunks +1 line, -3 lines 0 comments Download
M chrome/browser/extensions/pending_extension_manager.cc View 1 2 3 4 8 chunks +1 line, -13 lines 0 comments Download
M chrome/browser/extensions/updater/extension_updater_unittest.cc View 1 2 3 4 2 chunks +0 lines, -2 lines 0 comments Download
M chrome/browser/safe_browsing/incident_reporting/extension_data_collection.cc View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/supervised_user/supervised_user_service.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +19 lines, -0 lines 0 comments Download
M chrome/browser/supervised_user/supervised_user_service.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 4 chunks +38 lines, -39 lines 0 comments Download
M chrome/browser/supervised_user/supervised_user_service_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +5 lines, -4 lines 0 comments Download
M chrome/browser/sync/test/integration/two_client_apps_sync_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/themes/theme_syncable_service.cc View 1 2 1 chunk +1 line, -3 lines 0 comments Download
M extensions/common/extension.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +2 lines, -6 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 68 (21 generated)
mamir
4 years, 6 months ago (2016-06-10 17:18:13 UTC) #3
Marc Treib
Please add a bug, and update CL description and title. https://codereview.chromium.org/2054773002/diff/20001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/20001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1699 ...
4 years, 6 months ago (2016-06-13 09:37:14 UTC) #4
mamir
https://codereview.chromium.org/2054773002/diff/20001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/20001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1699 chrome/browser/extensions/extension_service_sync_unittest.cc:1699: sync_pb::EntitySpecifics specifics; On 2016/06/13 09:37:13, Marc Treib wrote: > ...
4 years, 6 months ago (2016-06-13 11:30:17 UTC) #7
Marc Treib
https://codereview.chromium.org/2054773002/diff/20001/extensions/browser/extension_prefs.h File extensions/browser/extension_prefs.h (right): https://codereview.chromium.org/2054773002/diff/20001/extensions/browser/extension_prefs.h#newcode415 extensions/browser/extension_prefs.h:415: bool IsInstalledByCustodian(const std::string& extension_id) const; On 2016/06/13 11:30:17, mamir ...
4 years, 6 months ago (2016-06-13 12:17:10 UTC) #8
Marc Treib
Ah, also please still update the CL description/title. "Fixing the bug of" isn't helpful to ...
4 years, 6 months ago (2016-06-13 12:19:56 UTC) #9
mamir
https://codereview.chromium.org/2054773002/diff/20001/extensions/browser/extension_prefs.h File extensions/browser/extension_prefs.h (right): https://codereview.chromium.org/2054773002/diff/20001/extensions/browser/extension_prefs.h#newcode415 extensions/browser/extension_prefs.h:415: bool IsInstalledByCustodian(const std::string& extension_id) const; On 2016/06/13 12:17:09, Marc ...
4 years, 6 months ago (2016-06-13 14:15:57 UTC) #11
Marc Treib
Thanks! LGTM with one more description nit: "the "WasInstalledByCustodian" flag is reset to false ignoring ...
4 years, 6 months ago (2016-06-13 14:36:51 UTC) #12
Devlin
https://codereview.chromium.org/2054773002/diff/60001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/60001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1704 chrome/browser/extensions/extension_service_sync_unittest.cc:1704: // It should not be enabled now (it is ...
4 years, 6 months ago (2016-06-13 14:36:58 UTC) #13
Devlin
also, please wrap CL title and description to 72 chars to be git-friendly. :)
4 years, 6 months ago (2016-06-13 14:37:32 UTC) #14
mamir
https://codereview.chromium.org/2054773002/diff/60001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/60001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1704 chrome/browser/extensions/extension_service_sync_unittest.cc:1704: // It should not be enabled now (it is ...
4 years, 6 months ago (2016-06-13 15:25:31 UTC) #17
Devlin
https://codereview.chromium.org/2054773002/diff/60001/extensions/browser/extension_prefs.h File extensions/browser/extension_prefs.h (right): https://codereview.chromium.org/2054773002/diff/60001/extensions/browser/extension_prefs.h#newcode416 extensions/browser/extension_prefs.h:416: void SetWasInstalledByCustodian(const std::string& extension_id, On 2016/06/13 15:25:31, mamir wrote: ...
4 years, 6 months ago (2016-06-13 15:41:43 UTC) #18
mamir
https://codereview.chromium.org/2054773002/diff/60001/extensions/browser/extension_prefs.h File extensions/browser/extension_prefs.h (right): https://codereview.chromium.org/2054773002/diff/60001/extensions/browser/extension_prefs.h#newcode416 extensions/browser/extension_prefs.h:416: void SetWasInstalledByCustodian(const std::string& extension_id, On 2016/06/13 15:41:43, Devlin wrote: ...
4 years, 6 months ago (2016-06-13 18:02:47 UTC) #19
Devlin
lgtm https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc#newcode239 chrome/browser/extensions/extension_util.cc:239: maybe also: if (!extension) return; https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/installed_loader.cc File chrome/browser/extensions/installed_loader.cc ...
4 years, 6 months ago (2016-06-15 00:30:36 UTC) #20
mamir
https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc#newcode239 chrome/browser/extensions/extension_util.cc:239: On 2016/06/15 00:30:36, Devlin wrote: > maybe also: > ...
4 years, 6 months ago (2016-06-15 09:54:41 UTC) #21
mamir
https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/100001/chrome/browser/extensions/extension_util.cc#newcode239 chrome/browser/extensions/extension_util.cc:239: On 2016/06/15 09:54:41, mamir wrote: > On 2016/06/15 00:30:36, ...
4 years, 6 months ago (2016-06-15 15:09:59 UTC) #22
mamir
4 years, 6 months ago (2016-06-15 15:10:02 UTC) #23
Marc Treib
https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If it is already enabled, nothing to be ...
4 years, 6 months ago (2016-06-16 12:35:39 UTC) #24
mamir
https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If it is already enabled, nothing to be ...
4 years, 6 months ago (2016-06-17 08:33:18 UTC) #25
Marc Treib
Mostly LG now, thanks! A few more small comments, and one actual question. https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc File ...
4 years, 6 months ago (2016-06-17 08:56:54 UTC) #26
mamir
https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/180001/chrome/browser/extensions/extension_util.cc#newcode239 chrome/browser/extensions/extension_util.cc:239: // If the extension is not installed, it may ...
4 years, 6 months ago (2016-06-17 16:12:55 UTC) #27
Marc Treib
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1732 chrome/browser/extensions/extension_service_sync_unittest.cc:1732: EXPECT_TRUE(registry()->enabled_extensions().GetByID(id)); nit: Contains instead of GetByID https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1768 chrome/browser/extensions/extension_service_sync_unittest.cc:1768: EXPECT_TRUE(registry()->enabled_extensions().GetByID(id)); ...
4 years, 6 months ago (2016-06-17 16:34:23 UTC) #29
mamir
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_service_sync_unittest.cc File chrome/browser/extensions/extension_service_sync_unittest.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_service_sync_unittest.cc#newcode1732 chrome/browser/extensions/extension_service_sync_unittest.cc:1732: EXPECT_TRUE(registry()->enabled_extensions().GetByID(id)); On 2016/06/17 16:34:22, Marc Treib wrote: > nit: ...
4 years, 6 months ago (2016-06-19 11:43:09 UTC) #30
Marc Treib
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If the installed_by_custodian flag is reset, do nothing. ...
4 years, 6 months ago (2016-06-20 12:42:28 UTC) #31
mamir
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If the installed_by_custodian flag is reset, do nothing. ...
4 years, 6 months ago (2016-06-20 12:46:46 UTC) #32
Marc Treib
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If the installed_by_custodian flag is reset, do nothing. ...
4 years, 6 months ago (2016-06-20 15:01:30 UTC) #33
mamir
https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/220001/chrome/browser/extensions/extension_util.cc#newcode235 chrome/browser/extensions/extension_util.cc:235: // If the installed_by_custodian flag is reset, do nothing. ...
4 years, 6 months ago (2016-06-20 16:08:08 UTC) #34
Marc Treib
https://codereview.chromium.org/2054773002/diff/260001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/260001/chrome/browser/extensions/extension_util.cc#newcode58 chrome/browser/extensions/extension_util.cc:58: // It is relevant only for supervised users nit: ...
4 years, 6 months ago (2016-06-20 16:42:39 UTC) #35
mamir
https://codereview.chromium.org/2054773002/diff/260001/chrome/browser/extensions/extension_util.cc File chrome/browser/extensions/extension_util.cc (right): https://codereview.chromium.org/2054773002/diff/260001/chrome/browser/extensions/extension_util.cc#newcode58 chrome/browser/extensions/extension_util.cc:58: // It is relevant only for supervised users On ...
4 years, 6 months ago (2016-06-20 16:55:45 UTC) #36
Marc Treib
LGTM again, thanks!
4 years, 6 months ago (2016-06-20 16:59:44 UTC) #37
Devlin
https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/extensions/extension_sync_service.cc File chrome/browser/extensions/extension_sync_service.cc (right): https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/extensions/extension_sync_service.cc#newcode321 chrome/browser/extensions/extension_sync_service.cc:321: extensions::util::SetWasInstalledByCustodian( It might be worth a comment: // Note: ...
4 years, 6 months ago (2016-06-20 17:09:25 UTC) #38
mamir
https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/extensions/extension_sync_service.cc File chrome/browser/extensions/extension_sync_service.cc (right): https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/extensions/extension_sync_service.cc#newcode321 chrome/browser/extensions/extension_sync_service.cc:321: extensions::util::SetWasInstalledByCustodian( On 2016/06/20 17:09:24, Devlin wrote: > It might ...
4 years, 6 months ago (2016-06-21 11:38:22 UTC) #39
mamir
caitkp@chromium.org: Please review changes in chrome/browser/safe_browsing/incident_reporting/extension_data_collection.cc pkotwicz@chromium.org: Please review changes in chrome/browser/themes/theme_syncable_service.cc
4 years, 6 months ago (2016-06-21 15:19:58 UTC) #41
pkotwicz
chrome/browser/themes/theme_syncable_service.cc rubberstamp LGTM
4 years, 6 months ago (2016-06-21 15:28:39 UTC) #42
pkotwicz
chrome/browser/themes/theme_syncable_service.cc rubberstamp LGTM
4 years, 6 months ago (2016-06-21 15:28:40 UTC) #43
pkotwicz
chrome/browser/themes/theme_syncable_service.cc rubberstamp LGTM
4 years, 6 months ago (2016-06-21 15:28:44 UTC) #44
Devlin
lgtm https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/supervised_user/supervised_user_service.cc File chrome/browser/supervised_user/supervised_user_service.cc (right): https://codereview.chromium.org/2054773002/diff/280001/chrome/browser/supervised_user/supervised_user_service.cc#newcode924 chrome/browser/supervised_user/supervised_user_service.cc:924: SupervisedUserService::ExtensionState SupervisedUserService::GetExtensionState( On 2016/06/21 11:38:22, mamir wrote: > ...
4 years, 6 months ago (2016-06-21 16:58:51 UTC) #45
Cait (Slow)
lgtm
4 years, 6 months ago (2016-06-21 17:30:17 UTC) #46
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2054773002/320001
4 years, 6 months ago (2016-06-22 12:07:04 UTC) #49
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_chromeos_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_chromeos_rel_ng/builds/232378) linux_chromium_compile_dbg_ng on tryserver.chromium.linux (JOB_FAILED, ...
4 years, 6 months ago (2016-06-22 12:25:01 UTC) #51
mamir
pavely@chromium.org: Please review changes in chrome/browser/sync/test/integration/two_client_apps_sync_test.cc
4 years, 6 months ago (2016-06-22 12:58:24 UTC) #53
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2054773002/340001
4 years, 6 months ago (2016-06-22 14:40:11 UTC) #55
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2054773002/340001
4 years, 6 months ago (2016-06-22 14:42:41 UTC) #58
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 6 months ago (2016-06-22 15:53:52 UTC) #60
pavely
chrome/browser/sync/test/integration/two_client_apps_sync_test.cc lgtm
4 years, 6 months ago (2016-06-22 17:02:30 UTC) #61
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2054773002/340001
4 years, 6 months ago (2016-06-22 17:03:48 UTC) #64
commit-bot: I haz the power
Committed patchset #18 (id:340001)
4 years, 6 months ago (2016-06-22 17:10:37 UTC) #66
commit-bot: I haz the power
4 years, 6 months ago (2016-06-22 17:13:38 UTC) #68
Message was sent while issue was closed.
Patchset 18 (id:??) landed as
https://crrev.com/192d78833ff9297c754f59f20cb4e590d693a7c2
Cr-Commit-Position: refs/heads/master@{#401318}

Powered by Google App Engine
This is Rietveld 408576698