diff options
author | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2013-03-05 16:46:32 +0100 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2013-03-05 19:48:48 +0100 |
commit | b71abe5d67d9812bc49d667cacb0e1f0267ccee5 (patch) | |
tree | 42696fd8613ecf5db242f27efb34bcea795aeb06 /lib/x509/dn.c | |
parent | 291a467dbf4dd7576f899470c338bdd1bb483f02 (diff) | |
download | gnutls-b71abe5d67d9812bc49d667cacb0e1f0267ccee5.tar.gz |
Several optimizations on certificate comparisons including DN. This speeds up CA certificate loading, and certificate verification.
Diffstat (limited to 'lib/x509/dn.c')
-rw-r--r-- | lib/x509/dn.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/lib/x509/dn.c b/lib/x509/dn.c index 99d41ffcc5..817f7b9678 100644 --- a/lib/x509/dn.c +++ b/lib/x509/dn.c @@ -1069,32 +1069,6 @@ gnutls_x509_rdn_get_oid (const gnutls_datum_t * idn, } -/* - * Compares the DER encoded part of a DN. - * - * FIXME: use a real DN comparison algorithm. - * - * Returns 1 if the DN's match and (0) if they don't match. Otherwise - * a negative error code is returned to indicate error. - */ -int -_gnutls_x509_compare_raw_dn (const gnutls_datum_t * dn1, - const gnutls_datum_t * dn2) -{ - - if (dn1->size != dn2->size) - { - gnutls_assert (); - return 0; - } - if (memcmp (dn1->data, dn2->data, dn2->size) != 0) - { - gnutls_assert (); - return 0; - } - return 1; /* they match */ -} - /** * gnutls_x509_dn_export: * @dn: Holds the uint8_t DN object |