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

Unified Diff: chrome/browser/chromeos/login/session/user_session_manager.cc

Issue 419013003: Replace c/b/nss_context by a KeyedService. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added cert_database namespace. Created 6 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
Index: chrome/browser/chromeos/login/session/user_session_manager.cc
diff --git a/chrome/browser/chromeos/login/session/user_session_manager.cc b/chrome/browser/chromeos/login/session/user_session_manager.cc
index 4025315f6f262222101ee4b4fb21ba1b16daf8b9..0ecb53270df71a0443958d7f4e01b155a32fb4e8 100644
--- a/chrome/browser/chromeos/login/session/user_session_manager.cc
+++ b/chrome/browser/chromeos/login/session/user_session_manager.cc
@@ -41,7 +41,6 @@
#include "chrome/browser/google/google_brand_chromeos.h"
#include "chrome/browser/lifetime/application_lifetime.h"
#include "chrome/browser/net/crl_set_fetcher.h"
-#include "chrome/browser/net/nss_context.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "chrome/browser/rlz/rlz.h"
@@ -50,7 +49,6 @@
#include "chrome/common/chrome_switches.h"
#include "chrome/common/logging_chrome.h"
#include "chrome/common/pref_names.h"
-#include "chromeos/cert_loader.h"
#include "chromeos/chromeos_switches.h"
#include "chromeos/cryptohome/cryptohome_util.h"
#include "chromeos/dbus/cryptohome_client.h"
@@ -160,15 +158,6 @@ base::FilePath GetRlzDisabledFlagPath() {
}
#endif
-// Callback to GetNSSCertDatabaseForProfile. It starts CertLoader using the
-// provided NSS database. It must be called for primary user only.
-void OnGetNSSCertDatabaseForUser(net::NSSCertDatabase* database) {
- if (!CertLoader::IsInitialized())
- return;
-
- CertLoader::Get()->StartWithNSSDB(database);
-}
-
} // namespace
#if defined(ENABLE_RLZ)
@@ -809,7 +798,6 @@ void UserSessionManager::FinalizePrepareProfile(Profile* profile) {
ProfileHelper::Get()->GetUserByProfile(profile);
if (user_manager->GetPrimaryUser() == user) {
InitRlz(profile);
- InitializeCerts(profile);
InitializeCRLSetFetcher(user);
}
@@ -920,15 +908,6 @@ void UserSessionManager::InitRlzImpl(Profile* profile, bool disabled) {
#endif
}
-void UserSessionManager::InitializeCerts(Profile* profile) {
- // Now that the user profile has been initialized
- // |GetNSSCertDatabaseForProfile| is safe to be used.
- if (CertLoader::IsInitialized() && base::SysInfo::IsRunningOnChromeOS()) {
- GetNSSCertDatabaseForProfile(profile,
- base::Bind(&OnGetNSSCertDatabaseForUser));
- }
-}
-
void UserSessionManager::InitializeCRLSetFetcher(
const user_manager::User* user) {
const std::string username_hash = user->username_hash();

Powered by Google App Engine
This is Rietveld 408576698