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

Unified Diff: net/base/x509_certificate_nss.cc

Issue 165206: Use strict revocation flags only for EV verification.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Upload before checkin Created 11 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/base/x509_certificate_nss.cc
===================================================================
--- net/base/x509_certificate_nss.cc (revision 22856)
+++ net/base/x509_certificate_nss.cc (working copy)
@@ -364,11 +364,22 @@
CERT_REV_M_TEST_USING_THIS_METHOD |
CERT_REV_M_ALLOW_NETWORK_FETCHING |
CERT_REV_M_ALLOW_IMPLICIT_DEFAULT_SOURCE |
- CERT_REV_M_REQUIRE_INFO_ON_MISSING_SOURCE |
CERT_REV_M_STOP_TESTING_ON_FRESH_INFO;
PRUint64 revocation_method_independent_flags =
- CERT_REV_MI_TEST_ALL_LOCAL_INFORMATION_FIRST |
- CERT_REV_MI_REQUIRE_SOME_FRESH_INFO_AVAILABLE;
+ CERT_REV_MI_TEST_ALL_LOCAL_INFORMATION_FIRST;
+ if (policy_oids && num_policy_oids > 0) {
+ // EV verification requires revocation checking. Consider the certificate
+ // revoked if we don't have revocation info.
+ // TODO(wtc): Add a bool parameter to expressly specify we're doing EV
+ // verification or we want strict revocation flags.
+ revocation_method_flags |= CERT_REV_M_REQUIRE_INFO_ON_MISSING_SOURCE;
+ revocation_method_independent_flags |=
+ CERT_REV_MI_REQUIRE_SOME_FRESH_INFO_AVAILABLE;
+ } else {
+ revocation_method_flags |= CERT_REV_M_SKIP_TEST_ON_MISSING_SOURCE;
+ revocation_method_independent_flags |=
+ CERT_REV_MI_NO_OVERALL_INFO_REQUIREMENT;
+ }
PRUint64 method_flags[2];
method_flags[cert_revocation_method_crl] = revocation_method_flags;
method_flags[cert_revocation_method_ocsp] = revocation_method_flags;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698