KU_DECIPHER_ONLY = 8,
};
+ /* to be compliant with RFC 4945 specific KUs have to be included */
+ this->flags &= ~X509_IKE_COMPLIANT;
+
if (asn1_unwrap(&blob, &blob) == ASN1_BIT_STRING && blob.len)
{
int bit, byte, unused = blob.ptr[0];
case KU_CRL_SIGN:
this->flags |= X509_CRL_SIGN;
break;
- case KU_KEY_CERT_SIGN:
- /* we use the caBasicConstraint, MUST be set */
case KU_DIGITAL_SIGNATURE:
case KU_NON_REPUDIATION:
+ this->flags |= X509_IKE_COMPLIANT;
+ break;
+ case KU_KEY_CERT_SIGN:
+ /* we use the caBasicConstraint, MUST be set */
case KU_KEY_ENCIPHERMENT:
case KU_DATA_ENCIPHERMENT:
case KU_KEY_AGREEMENT:
parser = asn1_parser_create(certObjects, this->encoding);
+ /* unless we see a keyUsage extension we are compliant with RFC 4945 */
+ this->flags |= X509_IKE_COMPLIANT;
+
while (parser->iterate(parser, &objectID, &object))
{
u_int level = parser->get_level(parser)+1;