OLD | NEW |
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 #include "net/cert/cert_verify_proc.h" | 5 #include "net/cert/cert_verify_proc.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/callback_helpers.h" | 9 #include "base/callback_helpers.h" |
10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 return true; | 107 return true; |
108 } | 108 } |
109 | 109 |
110 } // namespace | 110 } // namespace |
111 | 111 |
112 class CertVerifyProcTest : public testing::Test { | 112 class CertVerifyProcTest : public testing::Test { |
113 public: | 113 public: |
114 CertVerifyProcTest() | 114 CertVerifyProcTest() |
115 : verify_proc_(CertVerifyProc::CreateDefault()) { | 115 : verify_proc_(CertVerifyProc::CreateDefault()) { |
116 } | 116 } |
117 virtual ~CertVerifyProcTest() {} | 117 ~CertVerifyProcTest() override {} |
118 | 118 |
119 protected: | 119 protected: |
120 bool SupportsAdditionalTrustAnchors() { | 120 bool SupportsAdditionalTrustAnchors() { |
121 return verify_proc_->SupportsAdditionalTrustAnchors(); | 121 return verify_proc_->SupportsAdditionalTrustAnchors(); |
122 } | 122 } |
123 | 123 |
124 int Verify(X509Certificate* cert, | 124 int Verify(X509Certificate* cert, |
125 const std::string& hostname, | 125 const std::string& hostname, |
126 int flags, | 126 int flags, |
127 CRLSet* crl_set, | 127 CRLSet* crl_set, |
(...skipping 1442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1570 EXPECT_TRUE(verify_result.cert_status & CERT_STATUS_COMMON_NAME_INVALID); | 1570 EXPECT_TRUE(verify_result.cert_status & CERT_STATUS_COMMON_NAME_INVALID); |
1571 } | 1571 } |
1572 } | 1572 } |
1573 | 1573 |
1574 WRAPPED_INSTANTIATE_TEST_CASE_P( | 1574 WRAPPED_INSTANTIATE_TEST_CASE_P( |
1575 VerifyName, | 1575 VerifyName, |
1576 CertVerifyProcNameTest, | 1576 CertVerifyProcNameTest, |
1577 testing::ValuesIn(kVerifyNameData)); | 1577 testing::ValuesIn(kVerifyNameData)); |
1578 | 1578 |
1579 } // namespace net | 1579 } // namespace net |
OLD | NEW |