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

Unified Diff: components/policy/core/common/cloud/cloud_policy_client.cc

Issue 2276593004: Device registration using an enrollment certificate from the PCA. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed constant. Created 4 years, 4 months 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: components/policy/core/common/cloud/cloud_policy_client.cc
diff --git a/components/policy/core/common/cloud/cloud_policy_client.cc b/components/policy/core/common/cloud/cloud_policy_client.cc
index 57d12c240004cb750d11a26a0cb138c64a1ad6b3..c122da2d9d2b566789c1092e85d376c82481a4ad 100644
--- a/components/policy/core/common/cloud/cloud_policy_client.cc
+++ b/components/policy/core/common/cloud/cloud_policy_client.cc
@@ -12,6 +12,7 @@
#include "base/logging.h"
#include "base/stl_util.h"
#include "components/policy/core/common/cloud/device_management_service.h"
+#include "components/policy/core/common/cloud/signing_service.h"
#include "google_apis/gaia/gaia_constants.h"
#include "google_apis/gaia/gaia_urls.h"
#include "net/url_request/url_request_context_getter.h"
@@ -271,13 +272,10 @@ void CloudPolicyClient::FetchPolicy() {
void CloudPolicyClient::FetchRobotAuthCodes(const std::string& auth_token) {
CHECK(is_registered());
- DCHECK(!auth_token.empty());
policy_fetch_request_job_.reset(service_->CreateJob(
DeviceManagementRequestJob::TYPE_API_AUTH_CODE_FETCH,
GetRequestContext()));
- // The credentials of a domain user are needed in order to mint a new OAuth2
- // authorization token for the robot account.
policy_fetch_request_job_->SetOAuthToken(auth_token);
policy_fetch_request_job_->SetDMToken(dm_token_);
policy_fetch_request_job_->SetClientID(client_id_);

Powered by Google App Engine
This is Rietveld 408576698