z/OS Cryptographic Services System SSL Programming
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


gsk_name_compare()

z/OS Cryptographic Services System SSL Programming
SC14-7495-00

Compares two X.509 names.

Format

#include <gskcms.h>

gsk_boolean gsk_name_compare (
                              x509_name *            name1,
                              x509_name *            name2)

Parameters

name1
Specifies the first name to be compared.
name2
Specifies the second name to be compared.

Results

Returns TRUE if the two x.509 names are the same and FALSE if the two x.509 names are different.

Usage

The gsk_name_compare() routine compares two X.509 names and return TRUE if the names are the same and FALSE if they are not the same.

Two names are considered equal if they contain the same sequence of attribute types and attribute values. Attribute values are considered equal if they represent the same character string. If a relative distinguished name (RDN) contains multiple attributes, the attributes must be specified in ascending order based on their ASN.1 DER encoding. Strings are always stored using UTF-8 encoding.When matching UTF-8 encoded attribute values (x509_string_utf8) in the X.509 names, System SSL uses a case sensitive (exact match) comparison.

Printable strings (gsk_string_printable) are a special case. Multiple spaces are treated as a single space and the comparison is not case-sensitive. Case-sensitive comparisons are used for all other string types.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014