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

Side by Side Diff: net/ssl/client_cert_store.h

Issue 2838243002: Remove client_certs from SSLCertRequestInfo. (Closed)
Patch Set: revert stray whitespace change Created 3 years, 7 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
« no previous file with comments | « net/socket/socket_test_util.cc ('k') | net/ssl/client_cert_store_mac.h » ('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 #ifndef NET_SSL_CLIENT_CERT_STORE_H_ 5 #ifndef NET_SSL_CLIENT_CERT_STORE_H_
6 #define NET_SSL_CLIENT_CERT_STORE_H_ 6 #define NET_SSL_CLIENT_CERT_STORE_H_
7 7
8 #include "base/callback_forward.h" 8 #include "base/callback_forward.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "net/base/net_export.h" 10 #include "net/base/net_export.h"
11 #include "net/cert/x509_certificate.h" 11 #include "net/cert/x509_certificate.h"
12 12
13 namespace net { 13 namespace net {
14 14
15 class SSLCertRequestInfo; 15 class SSLCertRequestInfo;
16 16
17 // A handle to a client certificate store to query matching certificates when a 17 // A handle to a client certificate store to query matching certificates when a
18 // server requests client auth. Note that there may be multiple ClientCertStore 18 // server requests client auth. Note that there may be multiple ClientCertStore
19 // objects corresponding to the same platform certificate store; each request 19 // objects corresponding to the same platform certificate store; each request
20 // gets its own uniquely owned handle. 20 // gets its own uniquely owned handle.
21 class NET_EXPORT ClientCertStore { 21 class NET_EXPORT ClientCertStore {
22 public: 22 public:
23 virtual ~ClientCertStore() {} 23 virtual ~ClientCertStore() {}
24 24
25 using ClientCertListCallback = base::Callback<void(CertificateList)>;
26
25 // Get client certs matching the |cert_request_info|. On completion, the 27 // Get client certs matching the |cert_request_info|. On completion, the
26 // results will be stored in |selected_certs| and the |callback| will be run. 28 // results will be stored in |selected_certs| and the |callback| will be run.
27 // The |callback| may be called sychronously. The caller must ensure the 29 // The |callback| may be called sychronously. The caller must ensure the
28 // ClientCertStore, |cert_request_info|, and |selected_certs| remain alive 30 // ClientCertStore and |cert_request_info| remain alive until the callback
29 // until the callback has been run. 31 // has been run.
30 virtual void GetClientCerts(const SSLCertRequestInfo& cert_request_info, 32 virtual void GetClientCerts(const SSLCertRequestInfo& cert_request_info,
31 CertificateList* selected_certs, 33 const ClientCertListCallback& callback) = 0;
32 const base::Closure& callback) = 0; 34
33 protected: 35 protected:
34 ClientCertStore() {} 36 ClientCertStore() {}
35 37
36 private: 38 private:
37 DISALLOW_COPY_AND_ASSIGN(ClientCertStore); 39 DISALLOW_COPY_AND_ASSIGN(ClientCertStore);
38 }; 40 };
39 41
40 } // namespace net 42 } // namespace net
41 43
42 #endif // NET_SSL_CLIENT_CERT_STORE_H_ 44 #endif // NET_SSL_CLIENT_CERT_STORE_H_
OLDNEW
« no previous file with comments | « net/socket/socket_test_util.cc ('k') | net/ssl/client_cert_store_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698