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

Unified Diff: chrome/browser/chromeos/policy/enrollment_config.h

Issue 2186623002: Minimal attestation-based enrollment flow. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Made ZTE independent of enterprise enrollment. 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: chrome/browser/chromeos/policy/enrollment_config.h
diff --git a/chrome/browser/chromeos/policy/enrollment_config.h b/chrome/browser/chromeos/policy/enrollment_config.h
index 03788c1e3facd5a8a41f34e6e7550fef29759d7d..f0668827332e2f49c27bfae5f5f33bdf328bd7dc 100644
--- a/chrome/browser/chromeos/policy/enrollment_config.h
+++ b/chrome/browser/chromeos/policy/enrollment_config.h
@@ -35,6 +35,10 @@ struct EnrollmentConfig {
MODE_SERVER_ADVERTISED,
// Recover from "spontaneous unenrollment", user can't skip.
MODE_RECOVERY,
+ // Start attestation-based enrollment.
+ MODE_ATTESTATION,
+ // Start attestation-based enrollment and only uses that.
+ MODE_ATTESTATION_FORCED,
};
// An enumeration of authentication mechanisms that can be used for
@@ -50,7 +54,17 @@ struct EnrollmentConfig {
};
// Whether enrollment should be triggered.
- bool should_enroll() const { return mode != MODE_NONE; }
+ bool should_enroll() const {
+ return should_enroll_with_attestation() || should_enroll_interactively();
+ }
+
+ // Whether attestation enrollment should be triggered.
+ bool should_enroll_with_attestation() const {
+ return auth_mechanism != AUTH_MECHANISM_INTERACTIVE;
+ }
+
+ // Whether interactive enrollment should be triggered.
+ bool should_enroll_interactively() const { return mode != MODE_NONE; }
// Whether enrollment is forced. The user can't skip the enrollment step
// during OOBE if this returns true.

Powered by Google App Engine
This is Rietveld 408576698