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

Side by Side Diff: net/cert/cert_verify_proc_android.cc

Issue 2735733003: Disable commonName matching for certificates (Closed)
Patch Set: Created 3 years, 9 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/cert_verify_proc.cc ('k') | net/cert/cert_verify_proc_ios.cc » ('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 (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_android.h" 5 #include "net/cert/cert_verify_proc_android.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
391 const CertificateList& additional_trust_anchors, 391 const CertificateList& additional_trust_anchors,
392 CertVerifyResult* verify_result) { 392 CertVerifyResult* verify_result) {
393 std::vector<std::string> cert_bytes; 393 std::vector<std::string> cert_bytes;
394 if (!GetChainDEREncodedBytes(cert, &cert_bytes)) 394 if (!GetChainDEREncodedBytes(cert, &cert_bytes))
395 return ERR_CERT_INVALID; 395 return ERR_CERT_INVALID;
396 if (!VerifyFromAndroidTrustManager(cert_bytes, hostname, 396 if (!VerifyFromAndroidTrustManager(cert_bytes, hostname,
397 g_cert_net_fetcher.Get(), verify_result)) { 397 g_cert_net_fetcher.Get(), verify_result)) {
398 NOTREACHED(); 398 NOTREACHED();
399 return ERR_FAILED; 399 return ERR_FAILED;
400 } 400 }
401
401 if (IsCertStatusError(verify_result->cert_status)) 402 if (IsCertStatusError(verify_result->cert_status))
402 return MapCertStatusToNetError(verify_result->cert_status); 403 return MapCertStatusToNetError(verify_result->cert_status);
403 404
404 return OK; 405 return OK;
405 } 406 }
406 407
407 } // namespace net 408 } // namespace net
OLDNEW
« no previous file with comments | « net/cert/cert_verify_proc.cc ('k') | net/cert/cert_verify_proc_ios.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698