OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/profiles/profile_io_data.h" | 5 #include "chrome/browser/profiles/profile_io_data.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 #if defined(OS_ANDROID) | 97 #if defined(OS_ANDROID) |
98 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_settings_android.h" | 98 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_settings_android.h" |
99 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_settings_factory_and
roid.h" | 99 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_settings_factory_and
roid.h" |
100 #include "components/data_reduction_proxy/common/data_reduction_proxy_switches.h
" | 100 #include "components/data_reduction_proxy/common/data_reduction_proxy_switches.h
" |
101 #endif // defined(OS_ANDROID) | 101 #endif // defined(OS_ANDROID) |
102 | 102 |
103 #if defined(OS_CHROMEOS) | 103 #if defined(OS_CHROMEOS) |
104 #include "chrome/browser/chromeos/drive/drive_protocol_handler.h" | 104 #include "chrome/browser/chromeos/drive/drive_protocol_handler.h" |
105 #include "chrome/browser/chromeos/login/startup_utils.h" | 105 #include "chrome/browser/chromeos/login/startup_utils.h" |
106 #include "chrome/browser/chromeos/login/users/user.h" | |
107 #include "chrome/browser/chromeos/login/users/user_manager.h" | 106 #include "chrome/browser/chromeos/login/users/user_manager.h" |
108 #include "chrome/browser/chromeos/net/cert_verify_proc_chromeos.h" | 107 #include "chrome/browser/chromeos/net/cert_verify_proc_chromeos.h" |
109 #include "chrome/browser/chromeos/policy/policy_cert_service.h" | 108 #include "chrome/browser/chromeos/policy/policy_cert_service.h" |
110 #include "chrome/browser/chromeos/policy/policy_cert_service_factory.h" | 109 #include "chrome/browser/chromeos/policy/policy_cert_service_factory.h" |
111 #include "chrome/browser/chromeos/policy/policy_cert_verifier.h" | 110 #include "chrome/browser/chromeos/policy/policy_cert_verifier.h" |
112 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 111 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
113 #include "chrome/browser/chromeos/settings/cros_settings.h" | 112 #include "chrome/browser/chromeos/settings/cros_settings.h" |
114 #include "chromeos/dbus/cryptohome_client.h" | 113 #include "chromeos/dbus/cryptohome_client.h" |
115 #include "chromeos/dbus/dbus_thread_manager.h" | 114 #include "chromeos/dbus/dbus_thread_manager.h" |
116 #include "chromeos/settings/cros_settings_names.h" | 115 #include "chromeos/settings/cros_settings_names.h" |
| 116 #include "components/user_manager/user.h" |
117 #include "crypto/nss_util.h" | 117 #include "crypto/nss_util.h" |
118 #include "crypto/nss_util_internal.h" | 118 #include "crypto/nss_util_internal.h" |
119 #include "net/cert/multi_threaded_cert_verifier.h" | 119 #include "net/cert/multi_threaded_cert_verifier.h" |
120 #include "net/ssl/client_cert_store_chromeos.h" | 120 #include "net/ssl/client_cert_store_chromeos.h" |
121 #endif // defined(OS_CHROMEOS) | 121 #endif // defined(OS_CHROMEOS) |
122 | 122 |
123 #if defined(USE_NSS) | 123 #if defined(USE_NSS) |
124 #include "chrome/browser/ui/crypto_module_delegate_nss.h" | 124 #include "chrome/browser/ui/crypto_module_delegate_nss.h" |
125 #include "net/ssl/client_cert_store_nss.h" | 125 #include "net/ssl/client_cert_store_nss.h" |
126 #endif | 126 #endif |
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
353 profile->GetProxyConfigTracker())); | 353 profile->GetProxyConfigTracker())); |
354 #if defined(ENABLE_MANAGED_USERS) | 354 #if defined(ENABLE_MANAGED_USERS) |
355 SupervisedUserService* supervised_user_service = | 355 SupervisedUserService* supervised_user_service = |
356 SupervisedUserServiceFactory::GetForProfile(profile); | 356 SupervisedUserServiceFactory::GetForProfile(profile); |
357 params->supervised_user_url_filter = | 357 params->supervised_user_url_filter = |
358 supervised_user_service->GetURLFilterForIOThread(); | 358 supervised_user_service->GetURLFilterForIOThread(); |
359 #endif | 359 #endif |
360 #if defined(OS_CHROMEOS) | 360 #if defined(OS_CHROMEOS) |
361 chromeos::UserManager* user_manager = chromeos::UserManager::Get(); | 361 chromeos::UserManager* user_manager = chromeos::UserManager::Get(); |
362 if (user_manager) { | 362 if (user_manager) { |
363 chromeos::User* user = | 363 user_manager::User* user = |
364 chromeos::ProfileHelper::Get()->GetUserByProfile(profile); | 364 chromeos::ProfileHelper::Get()->GetUserByProfile(profile); |
365 // No need to initialize NSS for users with empty username hash: | 365 // No need to initialize NSS for users with empty username hash: |
366 // Getters for a user's NSS slots always return NULL slot if the user's | 366 // Getters for a user's NSS slots always return NULL slot if the user's |
367 // username hash is empty, even when the NSS is not initialized for the | 367 // username hash is empty, even when the NSS is not initialized for the |
368 // user. | 368 // user. |
369 if (user && !user->username_hash().empty()) { | 369 if (user && !user->username_hash().empty()) { |
370 params->username_hash = user->username_hash(); | 370 params->username_hash = user->username_hash(); |
371 DCHECK(!params->username_hash.empty()); | 371 DCHECK(!params->username_hash.empty()); |
372 BrowserThread::PostTask(BrowserThread::IO, | 372 BrowserThread::PostTask(BrowserThread::IO, |
373 FROM_HERE, | 373 FROM_HERE, |
(...skipping 895 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1269 void ProfileIOData::SetCookieSettingsForTesting( | 1269 void ProfileIOData::SetCookieSettingsForTesting( |
1270 CookieSettings* cookie_settings) { | 1270 CookieSettings* cookie_settings) { |
1271 DCHECK(!cookie_settings_.get()); | 1271 DCHECK(!cookie_settings_.get()); |
1272 cookie_settings_ = cookie_settings; | 1272 cookie_settings_ = cookie_settings; |
1273 } | 1273 } |
1274 | 1274 |
1275 void ProfileIOData::set_signin_names_for_testing( | 1275 void ProfileIOData::set_signin_names_for_testing( |
1276 SigninNamesOnIOThread* signin_names) { | 1276 SigninNamesOnIOThread* signin_names) { |
1277 signin_names_.reset(signin_names); | 1277 signin_names_.reset(signin_names); |
1278 } | 1278 } |
OLD | NEW |