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

Unified Diff: net/cert/cert_verify_proc_openssl.cc

Issue 2610903003: [refactor] Extract the CertVerifyResult assignment of has_md2, has_md4, (Closed)
Patch Set: address comments Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/cert/cert_verify_proc_nss.cc ('k') | net/cert/cert_verify_proc_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/cert_verify_proc_openssl.cc
diff --git a/net/cert/cert_verify_proc_openssl.cc b/net/cert/cert_verify_proc_openssl.cc
index 988bdec1e2ef269edc09153d32663899778b6655..31543f54402428c3c943ebb091eb41d908c72ca3 100644
--- a/net/cert/cert_verify_proc_openssl.cc
+++ b/net/cert/cert_verify_proc_openssl.cc
@@ -108,22 +108,7 @@ void GetCertChainInfo(X509_STORE_CTX* store_ctx,
// Only check the algorithm status for certificates that are not in the
// trust store.
if (i < static_cast<size_t>(store_ctx->last_untrusted)) {
- int sig_alg = OBJ_obj2nid(cert->sig_alg->algorithm);
- if (sig_alg == NID_md2WithRSAEncryption) {
- verify_result->has_md2 = true;
- } else if (sig_alg == NID_md4WithRSAEncryption) {
- verify_result->has_md4 = true;
- } else if (sig_alg == NID_md5WithRSAEncryption ||
- sig_alg == NID_md5WithRSA) {
- verify_result->has_md5 = true;
- } else if (sig_alg == NID_sha1WithRSAEncryption ||
- sig_alg == NID_dsaWithSHA || sig_alg == NID_dsaWithSHA1 ||
- sig_alg == NID_dsaWithSHA1_2 || sig_alg == NID_sha1WithRSA ||
- sig_alg == NID_ecdsa_with_SHA1) {
- verify_result->has_sha1 = true;
- if (i == 0)
- verify_result->has_sha1_leaf = true;
- }
+ FillCertVerifyResultWeakSignature(cert, i == 0, verify_result);
}
}
« no previous file with comments | « net/cert/cert_verify_proc_nss.cc ('k') | net/cert/cert_verify_proc_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698