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

Unified Diff: net/socket/ssl_client_socket_nss.cc

Issue 376753002: Fix webui cert viewer showing wrong cert chain on NSS and no chain on OpenSSL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix test Created 6 years, 5 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 side-by-side diff with in-line comments
Download patch
« net/cert/x509_certificate.h ('K') | « net/cert/x509_certificate_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/ssl_client_socket_nss.cc
diff --git a/net/socket/ssl_client_socket_nss.cc b/net/socket/ssl_client_socket_nss.cc
index 6eca9649830d9bd0be60adbbcc11d4861a51256f..2b8b2345949d5b5b5e14283fb91a357032bfb61f 100644
--- a/net/socket/ssl_client_socket_nss.cc
+++ b/net/socket/ssl_client_socket_nss.cc
@@ -1426,12 +1426,7 @@ SECStatus SSLClientSocketNSS::Core::PlatformClientAuthHandler(
*result_certs = CERT_NewCertList();
*result_private_key = private_key;
- chain.push_back(core->ssl_config_.client_cert->os_cert_handle());
- const X509Certificate::OSCertHandles& intermediates =
- core->ssl_config_.client_cert->GetIntermediateCertificates();
- if (!intermediates.empty())
- chain.insert(chain.end(), intermediates.begin(), intermediates.end());
-
+ core->ssl_config_.client_cert->GetCertificateChain(&chain);
for (size_t i = 0, chain_count = chain.size(); i < chain_count; ++i) {
CSSM_DATA cert_data;
SecCertificateRef cert_ref = chain[i];
« net/cert/x509_certificate.h ('K') | « net/cert/x509_certificate_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698