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

Unified Diff: chrome/browser/chromeos/arc/arc_session_manager.cc

Issue 2513473006: Stop running arc container on supervised user creation flow (Closed)
Patch Set: 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/easy_unlock/bootstrap_user_flow.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/arc/arc_session_manager.cc
diff --git a/chrome/browser/chromeos/arc/arc_session_manager.cc b/chrome/browser/chromeos/arc/arc_session_manager.cc
index 21effca88e1741d7f087ae3c547c954e774f4945..9aa71eacdadc4821fc5ac23f99b6ac28c08a0102 100644
--- a/chrome/browser/chromeos/arc/arc_session_manager.cc
+++ b/chrome/browser/chromeos/arc/arc_session_manager.cc
@@ -22,6 +22,8 @@
#include "chrome/browser/chromeos/arc/optin/arc_optin_preference_handler.h"
#include "chrome/browser/chromeos/arc/policy/arc_android_management_checker.h"
#include "chrome/browser/chromeos/arc/policy/arc_policy_util.h"
+#include "chrome/browser/chromeos/login/user_flow.h"
+#include "chrome/browser/chromeos/login/users/chrome_user_manager.h"
#include "chrome/browser/chromeos/profiles/profile_helper.h"
#include "chrome/browser/lifetime/application_lifetime.h"
#include "chrome/browser/policy/profile_policy_connector.h"
@@ -168,6 +170,13 @@ bool ArcSessionManager::IsAllowedForProfile(const Profile* profile) {
return false;
}
+ chromeos::UserFlow* user_flow =
+ chromeos::ChromeUserManager::Get()->GetUserFlow(user->GetAccountId());
hidehiko 2016/11/22 03:34:48 Is there a case where user_flow is nullptr even in
yoshiki 2016/11/29 18:08:44 Done.
+ if (user_flow && !user_flow->CanStartArc()) {
+ VLOG(1) << "ARC is prohibited in the currenet user flow.";
Luis Héctor Chávez 2016/11/22 19:12:14 nit: s/currenet/current/. also, consider changing
yoshiki 2016/11/29 18:08:44 Done.
+ return false;
+ }
+
if (user_manager::UserManager::Get()
->IsCurrentUserCryptohomeDataEphemeral()) {
VLOG(2) << "Users with ephemeral data are not supported in Arc.";
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/easy_unlock/bootstrap_user_flow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698