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

Unified Diff: chrome/browser/managed_mode/chromeos/manager_password_service.cc

Issue 221813006: Various supervised user password fixes - 2 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix comments Created 6 years, 9 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 | « chrome/browser/chromeos/login/supervised_user_manager_impl.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/managed_mode/chromeos/manager_password_service.cc
diff --git a/chrome/browser/managed_mode/chromeos/manager_password_service.cc b/chrome/browser/managed_mode/chromeos/manager_password_service.cc
index e6d2070758dd95b93a82b2d97eea4bafde8938f7..9616c82b76bdb536896a5351b431c6608b02bd3f 100644
--- a/chrome/browser/managed_mode/chromeos/manager_password_service.cc
+++ b/chrome/browser/managed_mode/chromeos/manager_password_service.cc
@@ -192,6 +192,12 @@ void ManagerPasswordService::OnAddKeySuccess(
UserManager::Get()->GetSupervisedUserManager()->GetAuthentication();
int old_schema = auth->GetPasswordSchema(user_id);
auth->StorePasswordData(user_id, *password_data.get());
+
+ if (auth->HasIncompleteKey(user_id))
+ auth->MarkKeyIncomplete(user_id, false /* key is complete now */);
+
+ // Check if we have legacy labels for keys.
+ // TODO(antrim): Migrate it to GetLabels call once wad@ implement it.
if (old_schema == SupervisedUserAuthentication::SCHEMA_PLAIN) {
// 1) Add new manager key (using old key).
// 2) Remove old supervised user key.
« no previous file with comments | « chrome/browser/chromeos/login/supervised_user_manager_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698