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

Side by Side Diff: net/cert/internal/parsed_certificate.cc

Issue 1923433002: Certificate path builder for new certificate verification library (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: changes for review comment #20 Created 4 years, 5 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/cert/internal/parsed_certificate.h ('k') | net/cert/internal/path_builder.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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/internal/parsed_certificate.h" 5 #include "net/cert/internal/parsed_certificate.h"
6 6
7 #include "net/cert/internal/name_constraints.h" 7 #include "net/cert/internal/name_constraints.h"
8 #include "net/cert/internal/signature_algorithm.h" 8 #include "net/cert/internal/signature_algorithm.h"
9 #include "net/cert/internal/verify_name_match.h" 9 #include "net/cert/internal/verify_name_match.h"
10 #include "net/der/parser.h" 10 #include "net/der/parser.h"
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 return ParsedCertificate::CreateFromCertificateData( 155 return ParsedCertificate::CreateFromCertificateData(
156 reinterpret_cast<const uint8_t*>(data.data()), data.size(), 156 reinterpret_cast<const uint8_t*>(data.data()), data.size(),
157 DataSource::INTERNAL_COPY, options); 157 DataSource::INTERNAL_COPY, options);
158 } 158 }
159 159
160 bool ParsedCertificate::CreateAndAddToVector( 160 bool ParsedCertificate::CreateAndAddToVector(
161 const uint8_t* data, 161 const uint8_t* data,
162 size_t length, 162 size_t length,
163 DataSource source, 163 DataSource source,
164 const ParseCertificateOptions& options, 164 const ParseCertificateOptions& options,
165 std::vector<scoped_refptr<ParsedCertificate>>* chain) { 165 ParsedCertificateList* chain) {
166 scoped_refptr<ParsedCertificate> cert( 166 scoped_refptr<ParsedCertificate> cert(
167 CreateFromCertificateData(data, length, source, options)); 167 CreateFromCertificateData(data, length, source, options));
168 if (!cert) 168 if (!cert)
169 return false; 169 return false;
170 chain->push_back(std::move(cert)); 170 chain->push_back(std::move(cert));
171 return true; 171 return true;
172 } 172 }
173 173
174 } // namespace net 174 } // namespace net
OLDNEW
« no previous file with comments | « net/cert/internal/parsed_certificate.h ('k') | net/cert/internal/path_builder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698