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

Side by Side Diff: chrome/browser/net/ssl_config_service_manager_pref.cc

Issue 208713004: Move SSLConfig class from ssl_config_service.h to ssl_config.h (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/net/ssl_config_service_manager_pref_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "chrome/browser/net/ssl_config_service_manager.h" 4 #include "chrome/browser/net/ssl_config_service_manager.h"
5 5
6 #include <algorithm> 6 #include <algorithm>
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 new_config)); 268 new_config));
269 } 269 }
270 270
271 void SSLConfigServiceManagerPref::GetSSLConfigFromPrefs( 271 void SSLConfigServiceManagerPref::GetSSLConfigFromPrefs(
272 net::SSLConfig* config) { 272 net::SSLConfig* config) {
273 config->rev_checking_enabled = rev_checking_enabled_.GetValue(); 273 config->rev_checking_enabled = rev_checking_enabled_.GetValue();
274 config->rev_checking_required_local_anchors = 274 config->rev_checking_required_local_anchors =
275 rev_checking_required_local_anchors_.GetValue(); 275 rev_checking_required_local_anchors_.GetValue();
276 std::string version_min_str = ssl_version_min_.GetValue(); 276 std::string version_min_str = ssl_version_min_.GetValue();
277 std::string version_max_str = ssl_version_max_.GetValue(); 277 std::string version_max_str = ssl_version_max_.GetValue();
278 config->version_min = net::SSLConfigService::default_version_min(); 278 config->version_min = net::kDefaultSSLVersionMin;
279 config->version_max = net::SSLConfigService::default_version_max(); 279 config->version_max = net::kDefaultSSLVersionMax;
280 uint16 version_min = SSLProtocolVersionFromString(version_min_str); 280 uint16 version_min = SSLProtocolVersionFromString(version_min_str);
281 uint16 version_max = SSLProtocolVersionFromString(version_max_str); 281 uint16 version_max = SSLProtocolVersionFromString(version_max_str);
282 if (version_min) { 282 if (version_min) {
283 // TODO(wtc): get the minimum SSL protocol version supported by the 283 // TODO(wtc): get the minimum SSL protocol version supported by the
284 // SSLClientSocket class. Right now it happens to be the same as the 284 // SSLClientSocket class. Right now it happens to be the same as the
285 // default minimum SSL protocol version because we enable all supported 285 // default minimum SSL protocol version because we enable all supported
286 // versions by default. 286 // versions by default.
287 uint16 supported_version_min = config->version_min; 287 uint16 supported_version_min = config->version_min;
288 config->version_min = std::max(supported_version_min, version_min); 288 config->version_min = std::max(supported_version_min, version_min);
289 } 289 }
(...skipping 22 matching lines...) Expand all
312 // static 312 // static
313 SSLConfigServiceManager* SSLConfigServiceManager::CreateDefaultManager( 313 SSLConfigServiceManager* SSLConfigServiceManager::CreateDefaultManager(
314 PrefService* local_state) { 314 PrefService* local_state) {
315 return new SSLConfigServiceManagerPref(local_state); 315 return new SSLConfigServiceManagerPref(local_state);
316 } 316 }
317 317
318 // static 318 // static
319 void SSLConfigServiceManager::RegisterPrefs(PrefRegistrySimple* registry) { 319 void SSLConfigServiceManager::RegisterPrefs(PrefRegistrySimple* registry) {
320 SSLConfigServiceManagerPref::RegisterPrefs(registry); 320 SSLConfigServiceManagerPref::RegisterPrefs(registry);
321 } 321 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/net/ssl_config_service_manager_pref_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698