summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorwtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-01 20:28:03 +0000
committerwtc@chromium.org <wtc@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-01 20:28:03 +0000
commit3dd6f5e0807447194b12c7adc9a730d81738a0a6 (patch)
tree6176f288326fdb65d167ce419929260209fff32b /chrome/browser
parent3f94a9eedbb0bd352beeea9ae65591c69c9012f1 (diff)
downloadchromium_src-3dd6f5e0807447194b12c7adc9a730d81738a0a6.zip
chromium_src-3dd6f5e0807447194b12c7adc9a730d81738a0a6.tar.gz
chromium_src-3dd6f5e0807447194b12c7adc9a730d81738a0a6.tar.bz2
Use SSLClientSocketNSS on Mac OS X. By default, chrome still uses
SSLClientSocketMac. Specify the --use-nss-for-ssl command-line option to use SSLClientSocketNSS. The nss.gyp in src/net/third_party/nss is renamed ssl.gyp to avoid a naming conflict with the nss.gyp in src/third_party/nss. The GYP generator for Xcode project files disallows same-named .gyp files. SSL client authentication doesn't work yet. R=mark BUG=30689 TEST=No build and test failures on Mac and Windows. Review URL: http://codereview.chromium.org/2322008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48650 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/browser_main.cc14
1 files changed, 11 insertions, 3 deletions
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc
index b777843..2d959c3 100644
--- a/chrome/browser/browser_main.cc
+++ b/chrome/browser/browser_main.cc
@@ -113,7 +113,6 @@
#include "app/l10n_util_win.h"
#include "app/win_util.h"
-#include "base/nss_util.h"
#include "base/registry.h"
#include "base/win_util.h"
#include "chrome/browser/browser.h"
@@ -133,7 +132,6 @@
#include "net/base/net_util.h"
#include "net/base/sdch_manager.h"
#include "net/base/winsock_init.h"
-#include "net/socket/ssl_client_socket_nss_factory.h"
#include "printing/printed_document.h"
#include "sandbox/src/sandbox.h"
#endif // defined(OS_WIN)
@@ -143,6 +141,11 @@
#include "chrome/browser/cocoa/install_from_dmg.h"
#endif
+#if defined(OS_MACOSX) || defined(OS_WIN)
+#include "base/nss_util.h"
+#include "net/socket/ssl_client_socket_nss_factory.h"
+#endif
+
#if defined(TOOLKIT_VIEWS)
#include "chrome/browser/views/chrome_views_delegate.h"
#include "views/focus/accelerator_handler.h"
@@ -757,8 +760,13 @@ int BrowserMain(const MainFunctionParams& parameters) {
}
}
+#if defined(OS_MACOSX) || defined(OS_WIN)
#if defined(OS_WIN)
- if (!parsed_command_line.HasSwitch(switches::kUseSChannel) ||
+ bool use_nss_for_ssl = !parsed_command_line.HasSwitch(switches::kUseSChannel);
+#else
+ bool use_nss_for_ssl = parsed_command_line.HasSwitch(switches::kUseNSSForSSL);
+#endif
+ if (use_nss_for_ssl ||
parsed_command_line.HasSwitch(switches::kUseSpdy) ||
is_spdy_trial) {
net::ClientSocketFactory::SetSSLClientSocketFactory(