diff options
author | agl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-12 15:23:54 +0000 |
---|---|---|
committer | agl@chromium.org <agl@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-12 15:23:54 +0000 |
commit | 03e09864d6b5738fab87b3d1e5aaeca35b0d08b6 (patch) | |
tree | 9c15dcd4f048b0f41b9a70d6b8ff683f2a36bb60 /net/base/cert_status_flags.cc | |
parent | e72f5d7292734d8108549eaa85b5f27f87823634 (diff) | |
download | chromium_src-03e09864d6b5738fab87b3d1e5aaeca35b0d08b6.zip chromium_src-03e09864d6b5738fab87b3d1e5aaeca35b0d08b6.tar.gz chromium_src-03e09864d6b5738fab87b3d1e5aaeca35b0d08b6.tar.bz2 |
Ignore revocation check failures from automated requests.
Extensions send requests without a TabContents, therefore we can't route SSL
errors to their SSLManager. Since, without a UI, we have to make a static
decision, this change makes it so that revocation check failures are ignored
for these requests.
BUG=86537
TEST=none
Review URL: http://codereview.chromium.org/8201011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@105082 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/cert_status_flags.cc')
-rw-r--r-- | net/base/cert_status_flags.cc | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/net/base/cert_status_flags.cc b/net/base/cert_status_flags.cc index 6f2efed..d897df5 100644 --- a/net/base/cert_status_flags.cc +++ b/net/base/cert_status_flags.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2009 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -9,6 +9,14 @@ namespace net { +bool IsCertStatusMinorError(CertStatus cert_status) { + static const CertStatus kMinorErrors = + CERT_STATUS_UNABLE_TO_CHECK_REVOCATION | + CERT_STATUS_NO_REVOCATION_MECHANISM; + cert_status &= CERT_STATUS_ALL_ERRORS; + return cert_status != 0 && (cert_status & ~kMinorErrors) == 0; +} + CertStatus MapNetErrorToCertStatus(int error) { switch (error) { case ERR_CERT_COMMON_NAME_INVALID: |