OpenBSD manual page server

Manual Page Search Parameters

X509_NAME_ENTRY_GET_OBJECT(3) Library Functions Manual X509_NAME_ENTRY_GET_OBJECT(3)

X509_NAME_ENTRY_new, X509_NAME_ENTRY_free, X509_NAME_ENTRY_get_object, X509_NAME_ENTRY_get_data, X509_NAME_ENTRY_set_object, X509_NAME_ENTRY_set_data, X509_NAME_ENTRY_create_by_txt, X509_NAME_ENTRY_create_by_NID, X509_NAME_ENTRY_create_by_OBJX.501 relative distinguished name

#include <openssl/x509.h>


X509_NAME_ENTRY_free(X509_NAME_ENTRY* ne);

X509_NAME_ENTRY_get_object(X509_NAME_ENTRY *ne);

X509_NAME_ENTRY_get_data(X509_NAME_ENTRY *ne);

X509_NAME_ENTRY_set_object(X509_NAME_ENTRY *ne, ASN1_OBJECT *obj);

X509_NAME_ENTRY_set_data(X509_NAME_ENTRY *ne, int type, const unsigned char *bytes, int len);

X509_NAME_ENTRY_create_by_txt(X509_NAME_ENTRY **ne, const char *field, int type, const unsigned char *bytes, int len);

X509_NAME_ENTRY_create_by_NID(X509_NAME_ENTRY **ne, int nid, int type, unsigned char *bytes, int len);

X509_NAME_ENTRY_create_by_OBJ(X509_NAME_ENTRY **ne, ASN1_OBJECT *obj, int type, const unsigned char *bytes, int len);

An X.501 RelativeDistinguishedName is a set of field type and value pairs. It is the building block for constructing X.501 Name objects. This implementation only supports sets with one element, so an X509_NAME_ENTRY object contains only one field type and one value.

() allocates and initializes an empty X509_NAME_ENTRY object, representing an ASN.1 RelativeDistinguishedName structure defined in RFC 5280 section

() frees ne and the type and value contained in it.

() retrieves the field type of ne in an ASN1_OBJECT structure. () retrieves the field value of ne in an ASN1_STRING structure. These two functions can be used to examine an X509_NAME_ENTRY object as returned by X509_NAME_get_entry(3).

() sets the field type of ne to obj.

() sets the field value of ne to string type type and the value determined by bytes and len.

(), (), and () create and return an X509_NAME_ENTRY structure.

Except for () and (), these functions are rarely used because X509_NAME_ENTRY structures are almost always part of X509_NAME structures and the functions described in X509_NAME_add_entry_by_txt(3) are typically used to create and add new entries in a single operation.

The arguments of these functions support similar options to the similarly named ones described in X509_NAME_add_entry_by_txt(3). So for example type can be set to MBSTRING_ASC, but in the case of () the field type must be set first so the relevant field information can be looked up internally.

ERR_get_error(3), OBJ_nid2obj(3), X509_NAME_add_entry(3), X509_NAME_get_entry(3), X509_NAME_new(3)

RFC 5280: Internet X.509 Public Key Infrastructure Certificate and Certificate Revocation List (CRL) Profile

ITU-T Recommendation X.501, also known as ISO/IEC 9594-2: Information Technology Open Systems Interconnection The Directory: Models, section 9.3: Relative distinguished name

December 25, 2016 OpenBSD-6.1