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

Side by Side Diff: net/socket/ssl_client_socket_mac.cc

Issue 4091005: Remove SSL 2.0 support. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Sync with ToT Created 10 years 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 | « net/base/ssl_config_service_win_unittest.cc ('k') | net/socket/ssl_client_socket_nss.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "net/socket/ssl_client_socket_mac.h" 5 #include "net/socket/ssl_client_socket_mac.h"
6 6
7 #include <CoreServices/CoreServices.h> 7 #include <CoreServices/CoreServices.h>
8 #include <netdb.h> 8 #include <netdb.h>
9 #include <sys/socket.h> 9 #include <sys/socket.h>
10 #include <sys/types.h> 10 #include <sys/types.h>
(...skipping 751 matching lines...) Expand 10 before | Expand all | Expand 10 after
762 int SSLClientSocketMac::InitializeSSLContext() { 762 int SSLClientSocketMac::InitializeSSLContext() {
763 VLOG(1) << "----- InitializeSSLContext"; 763 VLOG(1) << "----- InitializeSSLContext";
764 OSStatus status = noErr; 764 OSStatus status = noErr;
765 765
766 status = SSLNewContext(false, &ssl_context_); 766 status = SSLNewContext(false, &ssl_context_);
767 if (status) 767 if (status)
768 return NetErrorFromOSStatus(status); 768 return NetErrorFromOSStatus(status);
769 769
770 status = SSLSetProtocolVersionEnabled(ssl_context_, 770 status = SSLSetProtocolVersionEnabled(ssl_context_,
771 kSSLProtocol2, 771 kSSLProtocol2,
772 ssl_config_.ssl2_enabled); 772 false);
773 if (status) 773 if (status)
774 return NetErrorFromOSStatus(status); 774 return NetErrorFromOSStatus(status);
775 775
776 status = SSLSetProtocolVersionEnabled(ssl_context_, 776 status = SSLSetProtocolVersionEnabled(ssl_context_,
777 kSSLProtocol3, 777 kSSLProtocol3,
778 ssl_config_.ssl3_enabled); 778 ssl_config_.ssl3_enabled);
779 if (status) 779 if (status)
780 return NetErrorFromOSStatus(status); 780 return NetErrorFromOSStatus(status);
781 781
782 status = SSLSetProtocolVersionEnabled(ssl_context_, 782 status = SSLSetProtocolVersionEnabled(ssl_context_,
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
1319 if (rv < 0 && rv != ERR_IO_PENDING) { 1319 if (rv < 0 && rv != ERR_IO_PENDING) {
1320 us->write_io_buf_ = NULL; 1320 us->write_io_buf_ = NULL;
1321 return OSStatusFromNetError(rv); 1321 return OSStatusFromNetError(rv);
1322 } 1322 }
1323 1323
1324 // always lie to our caller 1324 // always lie to our caller
1325 return noErr; 1325 return noErr;
1326 } 1326 }
1327 1327
1328 } // namespace net 1328 } // namespace net
OLDNEW
« no previous file with comments | « net/base/ssl_config_service_win_unittest.cc ('k') | net/socket/ssl_client_socket_nss.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698