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

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

Issue 7969023: For the SSL cert status, convert anonymous enum that gives bit values into a typedefed uint32. Th... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 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 | « net/http/http_transaction_unittest.h ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after
1134 new SSLErrorParams(net_error, status)); 1134 new SSLErrorParams(net_error, status));
1135 return net_error; 1135 return net_error;
1136 } 1136 }
1137 1137
1138 int SSLClientSocketMac::DoVerifyCert() { 1138 int SSLClientSocketMac::DoVerifyCert() {
1139 next_handshake_state_ = STATE_VERIFY_CERT_COMPLETE; 1139 next_handshake_state_ = STATE_VERIFY_CERT_COMPLETE;
1140 1140
1141 DCHECK(server_cert_); 1141 DCHECK(server_cert_);
1142 1142
1143 VLOG(1) << "DoVerifyCert..."; 1143 VLOG(1) << "DoVerifyCert...";
1144 int cert_status; 1144 CertStatus cert_status;
1145 if (ssl_config_.IsAllowedBadCert(server_cert_, &cert_status)) { 1145 if (ssl_config_.IsAllowedBadCert(server_cert_, &cert_status)) {
1146 VLOG(1) << "Received an expected bad cert with status: " << cert_status; 1146 VLOG(1) << "Received an expected bad cert with status: " << cert_status;
1147 server_cert_verify_result_.Reset(); 1147 server_cert_verify_result_.Reset();
1148 server_cert_verify_result_.cert_status = cert_status; 1148 server_cert_verify_result_.cert_status = cert_status;
1149 server_cert_verify_result_.verified_cert = server_cert_; 1149 server_cert_verify_result_.verified_cert = server_cert_;
1150 return OK; 1150 return OK;
1151 } 1151 }
1152 1152
1153 int flags = 0; 1153 int flags = 0;
1154 if (ssl_config_.rev_checking_enabled) 1154 if (ssl_config_.rev_checking_enabled)
(...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
1415 if (rv < 0 && rv != ERR_IO_PENDING) { 1415 if (rv < 0 && rv != ERR_IO_PENDING) {
1416 us->write_io_buf_ = NULL; 1416 us->write_io_buf_ = NULL;
1417 return OSStatusFromNetError(rv); 1417 return OSStatusFromNetError(rv);
1418 } 1418 }
1419 1419
1420 // always lie to our caller 1420 // always lie to our caller
1421 return noErr; 1421 return noErr;
1422 } 1422 }
1423 1423
1424 } // namespace net 1424 } // namespace net
OLDNEW
« no previous file with comments | « net/http/http_transaction_unittest.h ('k') | net/socket/ssl_client_socket_nss.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698