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

Side by Side Diff: net/ssl/client_cert_store_unittest-inl.h

Issue 1526783002: Build a chain in ClientCertStoreNSS to send intermediates to the server. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: WIP test does not work Created 4 years, 10 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
OLDNEW
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 NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_ 5 #ifndef NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_
6 #define NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_ 6 #define NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/files/file_path.h" 11 #include "base/files/file_path.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "net/base/test_data_directory.h" 14 #include "net/base/test_data_directory.h"
15 #include "net/ssl/ssl_cert_request_info.h" 15 #include "net/ssl/ssl_cert_request_info.h"
16 #include "net/test/cert_test_util.h" 16 #include "net/test/cert_test_util.h"
17 #include "testing/gtest/include/gtest/gtest.h" 17 #include "testing/gtest/include/gtest/gtest.h"
18 18
19 namespace net { 19 namespace net {
20 20
21 namespace { 21 namespace {
22 22
23 // "CN=B CA" - DER encoded DN of the issuer of client_1.pem 23 // "CN=B CA" - DER encoded DN of the issuer of client_1.pem
24 const unsigned char kAuthority1DN[] = { 24 const unsigned char kAuthority1DN[] = {
25 0x30, 0x0f, 0x31, 0x0d, 0x30, 0x0b, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 25 0x30, 0x0f, 0x31, 0x0d, 0x30, 0x0b, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c,
26 0x04, 0x42, 0x20, 0x43, 0x41 26 0x04, 0x42, 0x20, 0x43, 0x41
27 }; 27 };
28 28
29 // "CN=E CA" - DER encoded DN of the issuer of client_2.pem 29 // "CN=E CA" - DER encoded DN of the issuer of client_2.pem
30 unsigned char kAuthority2DN[] = { 30 const unsigned char kAuthority2DN[] = {
31 0x30, 0x0f, 0x31, 0x0d, 0x30, 0x0b, 0x06, 0x03, 0x55, 0x04, 0x03, 0x0c, 31 0x30, 0x0f, 0x31, 0x0d, 0x30, 0x0b, 0x06, 0x03, 0x55,
32 0x04, 0x45, 0x20, 0x43, 0x41 32 0x04, 0x03, 0x0c, 0x04, 0x45, 0x20, 0x43, 0x41,
33 }; 33 };
34 34
35 } // namespace 35 } // namespace
36 36
37 // Use a templated test to provide common testcases for all the platform 37 // Use a templated test to provide common testcases for all the platform
38 // implementations of ClientCertStore. These cases test the client cert 38 // implementations of ClientCertStore. These cases test the client cert
39 // filtering behavior. 39 // filtering behavior.
40 // 40 //
41 // NOTE: If any test cases are added, removed, or renamed, the 41 // NOTE: If any test cases are added, removed, or renamed, the
42 // REGISTER_TYPED_TEST_CASE_P macro at the bottom of this file must be updated. 42 // REGISTER_TYPED_TEST_CASE_P macro at the bottom of this file must be updated.
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 } 120 }
121 121
122 REGISTER_TYPED_TEST_CASE_P(ClientCertStoreTest, 122 REGISTER_TYPED_TEST_CASE_P(ClientCertStoreTest,
123 EmptyQuery, 123 EmptyQuery,
124 AllIssuersAllowed, 124 AllIssuersAllowed,
125 CertAuthorityFiltering); 125 CertAuthorityFiltering);
126 126
127 } // namespace net 127 } // namespace net
128 128
129 #endif // NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_ 129 #endif // NET_SSL_CLIENT_CERT_STORE_UNITTEST_INL_H_
OLDNEW
« net/ssl/client_cert_store_nss.cc ('K') | « net/ssl/client_cert_store_nss_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698