OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ |
6 #define CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ | 6 #define CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
44 // databases that pass the filter |cert_filter| and additionally return | 44 // databases that pass the filter |cert_filter| and additionally return |
45 // certificates provided by |cert_provider|. | 45 // certificates provided by |cert_provider|. |
46 ClientCertStoreChromeOS( | 46 ClientCertStoreChromeOS( |
47 std::unique_ptr<CertificateProvider> cert_provider, | 47 std::unique_ptr<CertificateProvider> cert_provider, |
48 std::unique_ptr<CertFilter> cert_filter, | 48 std::unique_ptr<CertFilter> cert_filter, |
49 const PasswordDelegateFactory& password_delegate_factory); | 49 const PasswordDelegateFactory& password_delegate_factory); |
50 ~ClientCertStoreChromeOS() override; | 50 ~ClientCertStoreChromeOS() override; |
51 | 51 |
52 // net::ClientCertStore: | 52 // net::ClientCertStore: |
53 void GetClientCerts(const net::SSLCertRequestInfo& cert_request_info, | 53 void GetClientCerts(const net::SSLCertRequestInfo& cert_request_info, |
54 const ClientCertListCallback& callback) override; | 54 net::CertificateList* selected_certs, |
| 55 const base::Closure& callback) override; |
55 | 56 |
56 private: | 57 private: |
57 void GotAdditionalCerts(const net::SSLCertRequestInfo* request, | 58 void GotAdditionalCerts(const net::SSLCertRequestInfo* request, |
58 const ClientCertListCallback& callback, | 59 net::CertificateList* selected_certs, |
| 60 const base::Closure& callback, |
59 const net::CertificateList& additional_certs); | 61 const net::CertificateList& additional_certs); |
60 | 62 |
61 net::CertificateList GetAndFilterCertsOnWorkerThread( | 63 void GetAndFilterCertsOnWorkerThread( |
62 std::unique_ptr<crypto::CryptoModuleBlockingPasswordDelegate> | 64 std::unique_ptr<crypto::CryptoModuleBlockingPasswordDelegate> |
63 password_delegate, | 65 password_delegate, |
64 const net::SSLCertRequestInfo* request, | 66 const net::SSLCertRequestInfo* request, |
65 const net::CertificateList& additional_certs); | 67 const net::CertificateList& additional_certs, |
| 68 net::CertificateList* selected_certs); |
66 | 69 |
67 std::unique_ptr<CertificateProvider> cert_provider_; | 70 std::unique_ptr<CertificateProvider> cert_provider_; |
68 std::unique_ptr<CertFilter> cert_filter_; | 71 std::unique_ptr<CertFilter> cert_filter_; |
69 | 72 |
70 // The factory for creating the delegate for requesting a password to a | 73 // The factory for creating the delegate for requesting a password to a |
71 // PKCS#11 token. May be null. | 74 // PKCS#11 token. May be null. |
72 PasswordDelegateFactory password_delegate_factory_; | 75 PasswordDelegateFactory password_delegate_factory_; |
73 | 76 |
74 DISALLOW_COPY_AND_ASSIGN(ClientCertStoreChromeOS); | 77 DISALLOW_COPY_AND_ASSIGN(ClientCertStoreChromeOS); |
75 }; | 78 }; |
76 | 79 |
77 } // namespace chromeos | 80 } // namespace chromeos |
78 | 81 |
79 #endif // CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ | 82 #endif // CHROME_BROWSER_CHROMEOS_NET_CLIENT_CERT_STORE_CHROMEOS_H_ |
OLD | NEW |