1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef NET_BASE_SSL_CONFIG_SERVICE_DEFAULTS_H_ 6 #define NET_BASE_SSL_CONFIG_SERVICE_DEFAULTS_H_ 7 8 #include "net/base/ssl_config_service.h" 9 10 namespace net { 11 12 // This SSLConfigService always returns the default SSLConfig settings. It is 13 // mainly useful for unittests, or for platforms that do not have a native 14 // implementation of SSLConfigService yet. 15 class SSLConfigServiceDefaults : public SSLConfigService { 16 public: 17 SSLConfigServiceDefaults() {} 18 19 // Store default SSL config settings in |config|. 20 virtual void GetSSLConfig(SSLConfig* config) { 21 *config = default_config_; 22 } 23 24 private: 25 virtual ~SSLConfigServiceDefaults() {} 26 27 // Default value of prefs. 28 const SSLConfig default_config_; 29 30 DISALLOW_COPY_AND_ASSIGN(SSLConfigServiceDefaults); 31 }; 32 33 } // namespace net 34 35 #endif // NET_BASE_SSL_CONFIG_SERVICE_DEFAULTS_H_ 36