summaryrefslogtreecommitdiffstats
path: root/net/tools
diff options
context:
space:
mode:
authormattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-19 21:48:42 +0000
committermattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-19 21:48:42 +0000
commitdb36938cb26cf265a5fd93690a8e783d01406958 (patch)
tree7261d389592cdfbbb3063f223455518db12d3bda /net/tools
parent0d1872ebba9b790f3a33bcaecc11258ea924b397 (diff)
downloadchromium_src-db36938cb26cf265a5fd93690a8e783d01406958.zip
chromium_src-db36938cb26cf265a5fd93690a8e783d01406958.tar.gz
chromium_src-db36938cb26cf265a5fd93690a8e783d01406958.tar.bz2
Pref-backed SSLConfigService for Linux.
Makes SSLConfigService into a ref-counted interface, and makes Profile own an SSLConfigServiceFactory which is used to create the SSLConfigService and pass it through the URLRequestContext on down to where it is actually used. R=eroman,wtc BUG=11507,19290 Review URL: http://codereview.chromium.org/165003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@23757 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/tools')
-rw-r--r--net/tools/fetch/fetch_client.cc19
1 files changed, 17 insertions, 2 deletions
diff --git a/net/tools/fetch/fetch_client.cc b/net/tools/fetch/fetch_client.cc
index 0031ff4..f8b89df 100644
--- a/net/tools/fetch/fetch_client.cc
+++ b/net/tools/fetch/fetch_client.cc
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+#include "build/build_config.h"
+
#include "base/at_exit.h"
#include "base/command_line.h"
#include "base/message_loop.h"
@@ -12,6 +14,11 @@
#include "net/base/host_resolver.h"
#include "net/base/io_buffer.h"
#include "net/base/net_errors.h"
+#if defined(OS_WIN)
+#include "net/base/ssl_config_service_win.h"
+#else
+#include "net/base/ssl_config_service_defaults.h"
+#endif
#include "net/http/http_cache.h"
#include "net/http/http_network_layer.h"
#include "net/http/http_request_info.h"
@@ -132,13 +139,21 @@ int main(int argc, char**argv) {
net::CreateSystemHostResolver());
scoped_refptr<net::ProxyService> proxy_service(net::ProxyService::CreateNull());
+#if defined(OS_WIN)
+ scoped_refptr<net::SSLConfigService> ssl_config_service(
+ new net::SSLConfigServiceWin);
+#else
+ scoped_refptr<net::SSLConfigService> ssl_config_service(
+ new net::SSLConfigServiceDefaults);
+#endif
net::HttpTransactionFactory* factory = NULL;
if (use_cache) {
- factory = new net::HttpCache(host_resolver, proxy_service, 0);
+ factory = new net::HttpCache(host_resolver, proxy_service,
+ ssl_config_service, 0);
} else {
factory = new net::HttpNetworkLayer(
net::ClientSocketFactory::GetDefaultFactory(), host_resolver,
- proxy_service);
+ proxy_service, ssl_config_service);
}
{