CWE

Common Weakness Enumeration

A Community-Developed List of Software Weakness Types

CWE/SANS Top 25 Most Dangerous Software Errors
Home > CWE List > CWE- Individual Dictionary Definition (2.10)  
ID

CWE-299: Improper Check for Certificate Revocation

Weakness ID: 299
Abstraction: Variant
Status: Draft
Presentation Filter:
+ Description

Description Summary

The software does not check or incorrectly checks the revocation status of a certificate, which may cause it to use a certificate that has been compromised.

Extended Description

An improper check for certificate revocation is a far more serious flaw than related certificate failures. This is because the use of any revoked certificate is almost certainly malicious. The most common reason for certificate revocation is compromise of the system in question, with the result that no legitimate servers will be using a revoked certificate, unless they are sorely out of sync.

+ Time of Introduction
  • Architecture and Design
+ Applicable Platforms

Languages

Language-independent

+ Common Consequences
ScopeEffect
Access Control

Technical Impact: Gain privileges / assume identity

Trust may be assigned to an entity who is not who it claims to be.

Integrity
Other

Technical Impact: Other

Data from an untrusted (and possibly malicious) source may be integrated.

Confidentiality

Technical Impact: Read application data

Data may be disclosed to an entity impersonating a trusted entity, resulting in information disclosure.

+ Likelihood of Exploit

Medium

+ Demonstrative Examples

Example 1

The following OpenSSL code ensures that there is a certificate before continuing execution.

(Bad Code)
Example Languages: C and C++ 
if (cert = SSL_get_peer_certificate(ssl)) {
// got a certificate, do secret things

Because this code does not use SSL_get_verify_results() to check the certificate, it could accept certificates that have been revoked (X509_V_ERR_CERT_REVOKED). The software could be communicating with a malicious host.

+ Observed Examples
ReferenceDescription
LDAP-over-SSL implementation does not check Certificate Revocation List (CRL), allowing spoofing using a revoked certificate.
Operating system does not check Certificate Revocation List (CRL) in some cases, allowing spoofing using a revoked certificate.
Antivirus product does not check whether certificates from signed executables have been revoked.
Web browser does not check if any intermediate certificates are revoked.
chain: Ruby module for OCSP misinterprets a response, preventing detection of a revoked certificate.
chain: incorrect parsing of replies from OCSP responders allows bypass using a revoked certificate.
Router can permanently cache certain public keys, which would allow bypass if the certificate is later revoked.
chain: OS package manager does not properly check the return value, allowing bypass using a revoked certificate.
chain: language interpreter does not properly check the return value from an OSCP function, allowing bypass using a revoked certificate.
chain: web service component does not call the expected method, which prevents a check for revoked certificates.
Certificate revocation list not searched for certain certificates.
Product cannot access certificate revocation list when an HTTP proxy is being used.
+ Potential Mitigations

Phase: Architecture and Design

Ensure that certificates are checked for revoked status.

+ Relationships
NatureTypeIDNameView(s) this relationship pertains toView(s)
ChildOfWeakness BaseWeakness Base295Improper Certificate Validation
Development Concepts (primary)699
Research Concepts (primary)1000
ChildOfWeakness BaseWeakness Base404Improper Resource Shutdown or Release
Research Concepts1000
ChildOfCategoryCategory948SFP Secondary Cluster: Digital Certificate
Software Fault Pattern (SFP) Clusters (primary)888
ParentOfWeakness BaseWeakness Base370Missing Check for Certificate Revocation after Initial Check
Development Concepts (primary)699
Research Concepts (primary)1000
MemberOfViewView884CWE Cross-section
CWE Cross-section (primary)884
+ Taxonomy Mappings
Mapped Taxonomy NameNode IDFitMapped Node Name
CLASPFailure to check for certificate revocation
+ References
[REF-17] Michael Howard, David LeBlanc and John Viega. "24 Deadly Sins of Software Security". "Sin 23: Improper Use of PKI, Especially SSL." Page 347. McGraw-Hill. 2010.
+ Content History
Submissions
Submission DateSubmitterOrganizationSource
CLASPExternally Mined
Modifications
Modification DateModifierOrganizationSource
2008-07-01Eric DalciCigitalExternal
updated Time_of_Introduction
2008-09-08CWE Content TeamMITREInternal
updated Common_Consequences, Relationships, Other_Notes, Taxonomy_Mappings
2009-03-10CWE Content TeamMITREInternal
updated Description, Name, Relationships
2009-05-27CWE Content TeamMITREInternal
updated Relationships
2010-12-13CWE Content TeamMITREInternal
updated Other_Notes
2011-06-01CWE Content TeamMITREInternal
updated Common_Consequences
2012-05-11CWE Content TeamMITREInternal
updated References, Relationships
2013-02-21CWE Content TeamMITREInternal
updated Applicable_Platforms, Demonstrative_Examples, Description, Observed_Examples, Other_Notes, Relationships, Type
2013-07-17CWE Content TeamMITREInternal
updated Relationships
2014-07-30CWE Content TeamMITREInternal
updated Relationships
Previous Entry Names
Change DatePrevious Entry Name
2009-03-10Failure to Check for Certificate Revocation

More information is available — Please select a different filter.
Page Last Updated: January 18, 2017