pruned OID tree

This commit is contained in:
Andreas Steffen 2009-08-18 18:24:26 +02:00
parent c8b543a6fc
commit fc0ed07c1f
3 changed files with 9 additions and 16 deletions

View File

@ -91,8 +91,8 @@
0x05 "digestedData" OID_PKCS7_DIGESTED_DATA
0x06 "encryptedData" OID_PKCS7_ENCRYPTED_DATA
0x09 "PKCS-9"
0x01 "E" OID_PKCS9_EMAIL
0x02 "unstructuredName"
0x01 "E" OID_EMAIL_ADDRESS
0x02 "unstructuredName" OID_UNSTRUCTURED_NAME
0x03 "contentType" OID_PKCS9_CONTENT_TYPE
0x04 "messageDigest" OID_PKCS9_MESSAGE_DIGEST
0x05 "signingTime" OID_PKCS9_SIGNING_TIME
@ -293,10 +293,4 @@
0x06 "recipientNonce" OID_PKI_RECIPIENT_NONCE
0x07 "transID" OID_PKI_TRANS_ID
0x08 "extensionReq"
0x86 "old-netscape"
0xF7 ""
0x0D ""
0x01 ""
0x09 ""
0x01 "emailAddress" OID_EMAIL_ADDRESS
0x02 "unstructuredName" OID_UNSTRUCTURED_NAME

View File

@ -85,9 +85,9 @@ static const x501rdn_t x501rdns[] = {
{"ID", OID_UNIQUE_IDENTIFIER, ASN1_PRINTABLESTRING},
{"EN", OID_EMPLOYEE_NUMBER, ASN1_PRINTABLESTRING},
{"employeeNumber", OID_EMPLOYEE_NUMBER, ASN1_PRINTABLESTRING},
{"E", OID_PKCS9_EMAIL, ASN1_IA5STRING},
{"Email", OID_PKCS9_EMAIL, ASN1_IA5STRING},
{"emailAddress", OID_PKCS9_EMAIL, ASN1_IA5STRING},
{"E", OID_EMAIL_ADDRESS, ASN1_IA5STRING},
{"Email", OID_EMAIL_ADDRESS, ASN1_IA5STRING},
{"emailAddress", OID_EMAIL_ADDRESS, ASN1_IA5STRING},
{"UN", OID_UNSTRUCTURED_NAME, ASN1_IA5STRING},
{"unstructuredName",OID_UNSTRUCTURED_NAME, ASN1_IA5STRING},
{"TCGID", OID_TCGID, ASN1_PRINTABLESTRING}
@ -605,8 +605,7 @@ static bool compare_dn(chunk_t t_dn, chunk_t o_dn, int *wc)
if (t_type == o_type &&
(t_type == ASN1_PRINTABLESTRING ||
(t_type == ASN1_IA5STRING &&
(asn1_known_oid(t_oid) == OID_PKCS9_EMAIL ||
asn1_known_oid(t_oid) == OID_EMAIL_ADDRESS))))
asn1_known_oid(t_oid) == OID_EMAIL_ADDRESS)))
{ /* ignore case for printableStrings and email RDNs */
if (strncasecmp(t_data.ptr, o_data.ptr, t_data.len) != 0)
{

View File

@ -845,7 +845,7 @@ bool same_dn(chunk_t a, chunk_t b)
/* printableStrings and email RDNs require uppercase comparison */
if (type_a == type_b && (type_a == ASN1_PRINTABLESTRING ||
(type_a == ASN1_IA5STRING && asn1_known_oid(oid_a) == OID_PKCS9_EMAIL)))
(type_a == ASN1_IA5STRING && asn1_known_oid(oid_a) == OID_EMAIL_ADDRESS)))
{
if (strncasecmp(value_a.ptr, value_b.ptr, value_b.len) != 0)
{
@ -923,7 +923,7 @@ bool match_dn(chunk_t a, chunk_t b, int *wildcards)
/* printableStrings and email RDNs require uppercase comparison */
if (type_a == type_b && (type_a == ASN1_PRINTABLESTRING ||
(type_a == ASN1_IA5STRING && asn1_known_oid(oid_a) == OID_PKCS9_EMAIL)))
(type_a == ASN1_IA5STRING && asn1_known_oid(oid_a) == OID_EMAIL_ADDRESS)))
{
if (strncasecmp(value_a.ptr, value_b.ptr, value_b.len) != 0)
{