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

Unified Diff: chromeos/login/auth/login_performer.cc

Issue 1425093004: Revert of This CL replaces user_manager::UserID with AccountId. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@468875--Chrome-OS-handles-deletion-of-Gmail-account-poorly--Create-AccountID-structure-part2--user_names
Patch Set: Created 5 years, 2 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
« no previous file with comments | « chromeos/login/auth/fake_extended_authenticator.cc ('k') | chromeos/login/auth/stub_authenticator.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/login/auth/login_performer.cc
diff --git a/chromeos/login/auth/login_performer.cc b/chromeos/login/auth/login_performer.cc
index b988f1d3786382e5017e1c033355d1416438b360..ba4e82bd3b0657de4cc10d421d8b4da9ead4e0d1 100644
--- a/chromeos/login/auth/login_performer.cc
+++ b/chromeos/login/auth/login_performer.cc
@@ -18,7 +18,6 @@
#include "chromeos/login/user_names.h"
#include "chromeos/login_event_recorder.h"
#include "chromeos/settings/cros_settings_names.h"
-#include "components/signin/core/account_id/account_id.h"
#include "google_apis/gaia/gaia_auth_util.h"
#include "net/cookies/cookie_monster.h"
#include "net/cookies/cookie_store.h"
@@ -108,8 +107,7 @@
void LoginPerformer::NotifyWhitelistCheckFailure() {
if (delegate_)
- delegate_->WhiteListCheckFailed(
- user_context_.GetAccountId().GetUserEmail());
+ delegate_->WhiteListCheckFailed(user_context_.GetUserID());
else
NOTREACHED();
}
@@ -130,8 +128,7 @@
void LoginPerformer::DoPerformLogin(const UserContext& user_context,
AuthorizationMode auth_mode) {
- const std::string email =
- gaia::CanonicalizeEmail(user_context.GetAccountId().GetUserEmail());
+ std::string email = gaia::CanonicalizeEmail(user_context.GetUserID());
bool wildcard_match = false;
if (!IsUserWhitelisted(email, &wildcard_match)) {
@@ -140,7 +137,7 @@
}
if (user_context.GetAuthFlow() == UserContext::AUTH_FLOW_EASY_UNLOCK)
- SetupEasyUnlockUserFlow(user_context.GetAccountId().GetUserEmail());
+ SetupEasyUnlockUserFlow(user_context.GetUserID());
switch (auth_mode_) {
case AUTH_MODE_EXTENSION: {
@@ -159,9 +156,8 @@
}
void LoginPerformer::LoginAsSupervisedUser(const UserContext& user_context) {
- DCHECK_EQ(
- chromeos::login::kSupervisedUserDomain,
- gaia::ExtractDomainName(user_context.GetAccountId().GetUserEmail()));
+ DCHECK_EQ(chromeos::login::kSupervisedUserDomain,
+ gaia::ExtractDomainName(user_context.GetUserID()));
user_context_ = user_context;
user_context_.SetUserType(user_manager::USER_TYPE_SUPERVISED);
@@ -178,11 +174,11 @@
const UserContext& user_context) {
if (!AreSupervisedUsersAllowed()) {
LOG(ERROR) << "Login attempt of supervised user detected.";
- delegate_->WhiteListCheckFailed(user_context.GetAccountId().GetUserEmail());
- return;
- }
-
- SetupSupervisedUserFlow(user_context.GetAccountId().GetUserEmail());
+ delegate_->WhiteListCheckFailed(user_context.GetUserID());
+ return;
+ }
+
+ SetupSupervisedUserFlow(user_context.GetUserID());
UserContext user_context_copy = TransformSupervisedKey(user_context);
if (UseExtendedAuthenticatorForSupervisedUser(user_context)) {
@@ -206,7 +202,7 @@
}
void LoginPerformer::LoginAsPublicSession(const UserContext& user_context) {
- if (!CheckPolicyForUser(user_context.GetAccountId().GetUserEmail())) {
+ if (!CheckPolicyForUser(user_context.GetUserID())) {
DCHECK(delegate_);
if (delegate_)
delegate_->PolicyLoadFailed();
« no previous file with comments | « chromeos/login/auth/fake_extended_authenticator.cc ('k') | chromeos/login/auth/stub_authenticator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698