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

Unified Diff: chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc

Issue 2488573003: Expose signing key from cloud policy stores (Closed)
Patch Set: Fix tests Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc
diff --git a/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc b/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc
index b3bfde5f21bf78f3fa2c780e86239b174fc0ab6d..3fc16b0e838bbf1ffcb84ff929364b32126825fa 100644
--- a/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc
+++ b/chrome/browser/chromeos/policy/device_cloud_policy_store_chromeos.cc
@@ -198,6 +198,14 @@ void DeviceCloudPolicyStoreChromeOS::UpdateFromService() {
}
policy_map_.Swap(&new_policy_map);
+ DCHECK(owning_domain_.empty() ||
+ owning_domain_ == install_attributes_->GetDomain());
+ owning_domain_ = install_attributes_->GetDomain();
+
+ scoped_refptr<ownership::PublicKey> key =
+ device_settings_service_->GetPublicKey();
+ public_key_ = key ? key->as_string() : std::string();
+
NotifyStoreLoaded();
return;
}

Powered by Google App Engine
This is Rietveld 408576698