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

Unified Diff: chrome/browser/ssl/ssl_client_auth_observer.cc

Issue 1304143010: Plumbing SSLPrivateKey Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ssl/ssl_client_auth_observer.cc
diff --git a/chrome/browser/ssl/ssl_client_auth_observer.cc b/chrome/browser/ssl/ssl_client_auth_observer.cc
index 4a2dedb74822bb6ea55eacf54c087ce08714ed31..b37c1ada64308436d64c2e03023dc1d0bab8276b 100644
--- a/chrome/browser/ssl/ssl_client_auth_observer.cc
+++ b/chrome/browser/ssl/ssl_client_auth_observer.cc
@@ -14,6 +14,8 @@
#include "content/public/browser/notification_service.h"
#include "net/cert/x509_certificate.h"
#include "net/ssl/ssl_cert_request_info.h"
+#include "net/ssl/ssl_platform_key.h"
+#include "net/ssl/ssl_private_key.h"
using content::BrowserThread;
@@ -49,7 +51,10 @@ void SSLClientAuthObserver::CertificateSelected(
content::Source<content::BrowserContext>(browser_context_),
content::Details<CertDetails>(&details));
- delegate_->ContinueWithCertificate(certificate);
+ scoped_refptr<net::SSLPrivateKey> pkey =
+ FetchClientCertPrivateKey(certificate);
davidben 2015/09/25 20:10:11 [See comment at top of review. If I forget to type
svaldez 2015/09/28 16:54:52 Acknowledged.
+
+ delegate_->ContinueWithCertificate(certificate, pkey.get());
delegate_.reset();
}
@@ -78,7 +83,11 @@ void SSLClientAuthObserver::Observe(
DVLOG(1) << this << " got matching notification and selecting cert "
<< cert_details->second;
StopObserving();
- delegate_->ContinueWithCertificate(cert_details->second);
+
+ scoped_refptr<net::SSLPrivateKey> pkey =
+ FetchClientCertPrivateKey(cert_details->second);
+
+ delegate_->ContinueWithCertificate(cert_details->second, pkey.get());
delegate_.reset();
OnCertSelectedByNotification();
}

Powered by Google App Engine
This is Rietveld 408576698