Had an issue recently with a self-signed certificate that contained keyUsage extensions marked as critical. A number of KU flags were set, but the keyCertSign flag was not.
Attempting to connect to a SSL Server secured using this certificate fails as the OpenSSL verification routines throw it out. The same applies if a S/MIME message comes in signed with said certificate. In crypto/x509v3/v3_purp.c, there is the function X509_check_issued() around line 586 (OpenSSL 0.9.7c). The last check made in there is:- if(ku_reject(issuer, KU_KEY_CERT_SIGN)) return X509_V_ERR_KEYUSAGE_NO_CERTSIGN; A similar check is made for the SSL connection. So OpenSSL's opinion seems to be that if there are keyUsage extensions, but the keyCertSign flag is not set, then the certificate cannot be used for signing certificates, including itself. The people that I'm testing with (more than one) think that the limitation only applies to other certificates and not itself. So it cannot be a CA, and sign other certs, but it can sign it's own cert. Is this an ambiguity in the specification (which I've not read all of), or has one side made a proveable inaccurate interpretation? I've considered modifying the function such that it checks to see if the subject and the issuer certs are the same, in which case the keyUsage extensions can be ignored. Obviously though my concern is of breaking specifications and compliance. I'd appreciate your thoughts. - DR ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [EMAIL PROTECTED] Automated List Manager [EMAIL PROTECTED]