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

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

Issue 9478016: Merge 123620 - Set SSLInfo.client_cert_sent when origin bound cert was sent. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1025/src/
Patch Set: Created 8 years, 9 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/socket/socket_test_util.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 706 matching lines...) Expand 10 before | Expand all | Expand 10 after
717 void SSLClientSocketMac::GetSSLInfo(SSLInfo* ssl_info) { 717 void SSLClientSocketMac::GetSSLInfo(SSLInfo* ssl_info) {
718 ssl_info->Reset(); 718 ssl_info->Reset();
719 if (!server_cert_) 719 if (!server_cert_)
720 return; 720 return;
721 721
722 ssl_info->cert = server_cert_; 722 ssl_info->cert = server_cert_;
723 ssl_info->cert_status = server_cert_verify_result_.cert_status; 723 ssl_info->cert_status = server_cert_verify_result_.cert_status;
724 ssl_info->public_key_hashes = server_cert_verify_result_.public_key_hashes; 724 ssl_info->public_key_hashes = server_cert_verify_result_.public_key_hashes;
725 ssl_info->is_issued_by_known_root = 725 ssl_info->is_issued_by_known_root =
726 server_cert_verify_result_.is_issued_by_known_root; 726 server_cert_verify_result_.is_issued_by_known_root;
727 ssl_info->client_cert_sent = 727 ssl_info->client_cert_sent = WasOriginBoundCertSent() ||
728 ssl_config_.send_client_cert && ssl_config_.client_cert; 728 (ssl_config_.send_client_cert && ssl_config_.client_cert);
729 729
730 // security info 730 // security info
731 SSLCipherSuite suite; 731 SSLCipherSuite suite;
732 OSStatus status = SSLGetNegotiatedCipher(ssl_context_, &suite); 732 OSStatus status = SSLGetNegotiatedCipher(ssl_context_, &suite);
733 if (!status) { 733 if (!status) {
734 ssl_info->security_bits = KeySizeOfCipherSuite(suite); 734 ssl_info->security_bits = KeySizeOfCipherSuite(suite);
735 ssl_info->connection_status |= 735 ssl_info->connection_status |=
736 (suite & SSL_CONNECTION_CIPHERSUITE_MASK) << 736 (suite & SSL_CONNECTION_CIPHERSUITE_MASK) <<
737 SSL_CONNECTION_CIPHERSUITE_SHIFT; 737 SSL_CONNECTION_CIPHERSUITE_SHIFT;
738 } 738 }
(...skipping 687 matching lines...) Expand 10 before | Expand all | Expand 10 after
1426 if (rv < 0 && rv != ERR_IO_PENDING) { 1426 if (rv < 0 && rv != ERR_IO_PENDING) {
1427 us->write_io_buf_ = NULL; 1427 us->write_io_buf_ = NULL;
1428 return OSStatusFromNetError(rv); 1428 return OSStatusFromNetError(rv);
1429 } 1429 }
1430 1430
1431 // always lie to our caller 1431 // always lie to our caller
1432 return noErr; 1432 return noErr;
1433 } 1433 }
1434 1434
1435 } // namespace net 1435 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/socket_test_util.cc ('k') | net/socket/ssl_client_socket_nss.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698