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

Unified Diff: net/cert/x509_certificate.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
Index: net/cert/x509_certificate.cc
diff --git a/net/cert/x509_certificate.cc b/net/cert/x509_certificate.cc
index 052b7b7ecc166a76f8638584a200c657e8656fc6..d46c58448c5c6536664937f93e79008b15cd4b38 100644
--- a/net/cert/x509_certificate.cc
+++ b/net/cert/x509_certificate.cc
@@ -499,6 +499,14 @@ bool X509Certificate::Equals(const X509Certificate* other) const {
return IsSameOSCert(cert_handle_, other->cert_handle_);
}
+void X509Certificate::GetCertificateChain(OSCertHandles* cert_chain) const {
+ cert_chain->clear();
+ cert_chain->push_back(cert_handle_);
+ cert_chain->insert(cert_chain->end(),
+ intermediate_ca_certs_.begin(),
+ intermediate_ca_certs_.end());
+}
+
// static
bool X509Certificate::VerifyHostname(
const std::string& hostname,

Powered by Google App Engine
This is Rietveld 408576698