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
3 // found in the LICENSE file.
5 #ifndef NET_SSL_CLIENT_CERT_STORE_WIN_H_
6 #define NET_SSL_CLIENT_CERT_STORE_WIN_H_
8 #include "base/basictypes.h"
9 #include "base/callback.h"
10 #include "base/gtest_prod_util.h"
11 #include "net/base/net_export.h"
12 #include "net/ssl/client_cert_store.h"
13 #include "net/ssl/ssl_cert_request_info.h"
17 class NET_EXPORT ClientCertStoreWin
: public ClientCertStore
{
20 ~ClientCertStoreWin() override
;
23 void GetClientCerts(const SSLCertRequestInfo
& cert_request_info
,
24 CertificateList
* selected_certs
,
25 const base::Closure
& callback
) override
;
28 friend class ClientCertStoreWinTestDelegate
;
30 // A hook for testing. Filters |input_certs| using the logic being used to
31 // filter the system store when GetClientCerts() is called.
32 // Implemented by creating a temporary in-memory store and filtering it
33 // using the common logic.
34 bool SelectClientCertsForTesting(const CertificateList
& input_certs
,
35 const SSLCertRequestInfo
& cert_request_info
,
36 CertificateList
* selected_certs
);
38 DISALLOW_COPY_AND_ASSIGN(ClientCertStoreWin
);
43 #endif // NET_SSL_CLIENT_CERT_STORE_WIN_H_