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

Issue 2488573003: Expose signing key from cloud policy stores (Closed)

Created:
4 years, 1 month ago by emaxx
Modified:
4 years, 1 month ago
Reviewers:
Thiemo Nagel
CC:
chromium-reviews, oshima+watch_chromium.org, davemoore+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Expose signing key from cloud policy stores This change makes the cloud policy stores (user, device, device-local) to expose more information about the policies that they own: the public part of the signing key. This was not exposed by their interfaces previously. No behavior change is expected to be introduced by this CL. This change is intended to be a base for the subsequent implementation of the component cloud policy signature verification. BUG=644632 TEST=new unit tests Committed: https://crrev.com/cc11f1e65bc21e264ec3a763e9c0d36f2d9025b1 Cr-Commit-Position: refs/heads/master@{#433902}

Patch Set 1 #

Patch Set 2 : Fix test #

Patch Set 3 : Fix tests #

Total comments: 7

Patch Set 4 : Remove owning domain exposing #

Patch Set 5 : Address review feedback #

Patch Set 6 : Fix compilation #

Patch Set 7 : Simplify changes in DeviceLocalAccountPolicyStore #

Total comments: 3

Patch Set 8 : Rebase #

Patch Set 9 : Rebase #

Patch Set 10 : Rebase #

Total comments: 2

Patch Set 11 : Expose public key only on successful store #

Total comments: 10

Patch Set 12 : Some renamings according to feedback #

Total comments: 7

Patch Set 13 : Address feedback #

Patch Set 14 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+251 lines, -78 lines) Patch
M chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 18 chunks +44 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/policy/device_local_account_policy_store.h View 1 2 3 4 5 6 7 8 9 10 11 5 chunks +14 lines, -7 lines 0 comments Download
M chrome/browser/chromeos/policy/device_local_account_policy_store.cc View 1 2 3 4 5 6 7 8 9 10 11 5 chunks +12 lines, -4 lines 0 comments Download
M chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +8 lines, -3 lines 0 comments Download
M chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 10 chunks +19 lines, -21 lines 0 comments Download
M chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 28 chunks +83 lines, -6 lines 0 comments Download
M chrome/browser/policy/cloud/user_policy_signin_service_unittest.cc View 7 chunks +7 lines, -7 lines 0 comments Download
M components/policy/core/common/cloud/cloud_policy_store.h View 1 2 3 4 5 6 7 8 9 10 11 3 chunks +11 lines, -0 lines 0 comments Download
M components/policy/core/common/cloud/mock_cloud_policy_store.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -0 lines 0 comments Download
M components/policy/core/common/cloud/mock_user_cloud_policy_store.h View 1 chunk +0 lines, -1 line 0 comments Download
M components/policy/core/common/cloud/user_cloud_policy_store.h View 1 2 3 4 5 6 7 8 9 10 11 5 chunks +17 lines, -9 lines 0 comments Download
M components/policy/core/common/cloud/user_cloud_policy_store.cc View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +15 lines, -12 lines 0 comments Download
M components/policy/core/common/cloud/user_cloud_policy_store_base.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +4 lines, -2 lines 0 comments Download
M components/policy/core/common/cloud/user_cloud_policy_store_base.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +3 lines, -1 line 0 comments Download
M components/policy/core/common/cloud/user_cloud_policy_store_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +9 lines, -5 lines 0 comments Download

Messages

Total messages: 85 (64 generated)
emaxx
Thiemo, may I ask you to review this CL? It's part of a bigger change, ...
4 years, 1 month ago (2016-11-08 20:41:54 UTC) #12
emaxx
https://codereview.chromium.org/2488573003/diff/40001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos_unittest.cc File chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos_unittest.cc (right): https://codereview.chromium.org/2488573003/diff/40001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos_unittest.cc#newcode134 chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos_unittest.cc:134: std::string GetPolicyPublicKeyAsString() { I'd like to land a separate ...
4 years, 1 month ago (2016-11-08 20:53:37 UTC) #13
emaxx
As per our offline discussion, looks like owning domain is actually not needed to be ...
4 years, 1 month ago (2016-11-10 19:12:31 UTC) #20
Thiemo Nagel
https://codereview.chromium.org/2488573003/diff/40001/components/policy/core/common/cloud/cloud_policy_store.h File components/policy/core/common/cloud/cloud_policy_store.h (right): https://codereview.chromium.org/2488573003/diff/40001/components/policy/core/common/cloud/cloud_policy_store.h#newcode87 components/policy/core/common/cloud/cloud_policy_store.h:87: std::string owning_domain() const { return owning_domain_; } Nit: What ...
4 years, 1 month ago (2016-11-10 19:26:37 UTC) #21
emaxx
Thiemo, PTAL. I removed the owning domain exposing, and addressed the feedback from your first ...
4 years, 1 month ago (2016-11-10 21:07:19 UTC) #28
emaxx
Reduced changes in DeviceLocalAccountPolicyStore.
4 years, 1 month ago (2016-11-11 22:56:52 UTC) #34
Thiemo Nagel
I guess the CL needs a rebase and rerunning of the tests... https://codereview.chromium.org/2488573003/diff/120001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc File chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc ...
4 years, 1 month ago (2016-11-16 16:50:06 UTC) #35
emaxx
https://codereview.chromium.org/2488573003/diff/120001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc File chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc (right): https://codereview.chromium.org/2488573003/diff/120001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc#newcode203 chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc:203: public_key_ = key ? key->as_string() : std::string(); On 2016/11/16 ...
4 years, 1 month ago (2016-11-16 22:05:58 UTC) #48
emaxx
On 2016/11/16 16:50:06, Thiemo Nagel (slow) wrote: > I guess the CL needs a rebase ...
4 years, 1 month ago (2016-11-16 22:06:25 UTC) #49
Thiemo Nagel
https://codereview.chromium.org/2488573003/diff/120001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc File chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc (right): https://codereview.chromium.org/2488573003/diff/120001/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc#newcode203 chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc:203: public_key_ = key ? key->as_string() : std::string(); Sorry, I've ...
4 years, 1 month ago (2016-11-17 17:19:56 UTC) #54
emaxx
https://codereview.chromium.org/2488573003/diff/180001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc File chrome/browser/chromeos/policy/device_local_account_policy_store.cc (right): https://codereview.chromium.org/2488573003/diff/180001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc#newcode150 chrome/browser/chromeos/policy/device_local_account_policy_store.cc:150: public_key_ = key->as_string(); On 2016/11/17 17:19:56, Thiemo Nagel (slow) ...
4 years, 1 month ago (2016-11-17 18:44:55 UTC) #55
emaxx
On 2016/11/17 18:44:55, emaxx wrote: > https://codereview.chromium.org/2488573003/diff/180001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc > File chrome/browser/chromeos/policy/device_local_account_policy_store.cc > (right): > > https://codereview.chromium.org/2488573003/diff/180001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc#newcode150 ...
4 years, 1 month ago (2016-11-17 19:24:37 UTC) #56
emaxx
Thiemo, PTAL. I think I've made the semantics much clearer now: public key is updated ...
4 years, 1 month ago (2016-11-21 15:19:55 UTC) #59
Thiemo Nagel
https://codereview.chromium.org/2488573003/diff/200001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc File chrome/browser/chromeos/policy/device_local_account_policy_store.cc (right): https://codereview.chromium.org/2488573003/diff/200001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc#newcode142 chrome/browser/chromeos/policy/device_local_account_policy_store.cc:142: chromeos::DeviceSettingsService::OwnershipStatus ownership_status) { Nit: Since you're touching this code, ...
4 years, 1 month ago (2016-11-21 17:45:34 UTC) #60
emaxx
https://codereview.chromium.org/2488573003/diff/200001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc File chrome/browser/chromeos/policy/device_local_account_policy_store.cc (right): https://codereview.chromium.org/2488573003/diff/200001/chrome/browser/chromeos/policy/device_local_account_policy_store.cc#newcode142 chrome/browser/chromeos/policy/device_local_account_policy_store.cc:142: chromeos::DeviceSettingsService::OwnershipStatus ownership_status) { On 2016/11/21 17:45:33, Thiemo Nagel (slow) ...
4 years, 1 month ago (2016-11-21 20:04:58 UTC) #65
Thiemo Nagel
Lgtm. Thank you for your patience. https://codereview.chromium.org/2488573003/diff/220001/chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.cc File chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.cc (right): https://codereview.chromium.org/2488573003/diff/220001/chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.cc#newcode444 chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.cc:444: std::string() /* public_key ...
4 years, 1 month ago (2016-11-22 11:57:15 UTC) #68
emaxx
Thank you for reviewing this big CL! https://codereview.chromium.org/2488573003/diff/220001/chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h File chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h (right): https://codereview.chromium.org/2488573003/diff/220001/chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h#newcode135 chrome/browser/chromeos/policy/user_cloud_policy_store_chromeos.h:135: bool is_legacy_caches_load_performed_ ...
4 years, 1 month ago (2016-11-22 16:16:52 UTC) #75
Thiemo Nagel
still lgtm
4 years, 1 month ago (2016-11-22 16:49:36 UTC) #78
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/2488573003/260001
4 years, 1 month ago (2016-11-22 17:24:03 UTC) #80
commit-bot: I haz the power
Committed patchset #14 (id:260001)
4 years, 1 month ago (2016-11-22 17:29:23 UTC) #83
commit-bot: I haz the power
4 years, 1 month ago (2016-11-22 17:31:46 UTC) #85
Message was sent while issue was closed.
Patchset 14 (id:??) landed as
https://crrev.com/cc11f1e65bc21e264ec3a763e9c0d36f2d9025b1
Cr-Commit-Position: refs/heads/master@{#433902}

Powered by Google App Engine
This is Rietveld 408576698