1=pod 2 3=head1 NAME 4 5X509_NAME_ENTRY_get_object, X509_NAME_ENTRY_get_data, 6X509_NAME_ENTRY_set_object, X509_NAME_ENTRY_set_data, 7X509_NAME_ENTRY_create_by_txt, X509_NAME_ENTRY_create_by_NID, 8X509_NAME_ENTRY_create_by_OBJ - X509_NAME_ENTRY utility functions 9 10=head1 SYNOPSIS 11 12 #include <openssl/x509.h> 13 14 ASN1_OBJECT * X509_NAME_ENTRY_get_object(X509_NAME_ENTRY *ne); 15 ASN1_STRING * X509_NAME_ENTRY_get_data(X509_NAME_ENTRY *ne); 16 17 int X509_NAME_ENTRY_set_object(X509_NAME_ENTRY *ne, ASN1_OBJECT *obj); 18 int X509_NAME_ENTRY_set_data(X509_NAME_ENTRY *ne, int type, const unsigned char *bytes, int len); 19 20 X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_txt(X509_NAME_ENTRY **ne, const char *field, int type, const unsigned char *bytes, int len); 21 X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_NID(X509_NAME_ENTRY **ne, int nid, int type,unsigned char *bytes, int len); 22 X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_OBJ(X509_NAME_ENTRY **ne, ASN1_OBJECT *obj, int type, const unsigned char *bytes, int len); 23 24=head1 DESCRIPTION 25 26X509_NAME_ENTRY_get_object() retrieves the field name of B<ne> in 27and B<ASN1_OBJECT> structure. 28 29X509_NAME_ENTRY_get_data() retrieves the field value of B<ne> in 30and B<ASN1_STRING> structure. 31 32X509_NAME_ENTRY_set_object() sets the field name of B<ne> to B<obj>. 33 34X509_NAME_ENTRY_set_data() sets the field value of B<ne> to string type 35B<type> and value determined by B<bytes> and B<len>. 36 37X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_NID() 38and X509_NAME_ENTRY_create_by_OBJ() create and return an 39B<X509_NAME_ENTRY> structure. 40 41=head1 NOTES 42 43X509_NAME_ENTRY_get_object() and X509_NAME_ENTRY_get_data() can be 44used to examine an B<X509_NAME_ENTRY> function as returned by 45X509_NAME_get_entry() for example. 46 47X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_NID(), 48and X509_NAME_ENTRY_create_by_OBJ() create and return an 49 50X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_OBJ(), 51X509_NAME_ENTRY_create_by_NID() and X509_NAME_ENTRY_set_data() 52are seldom used in practice because B<X509_NAME_ENTRY> structures 53are almost always part of B<X509_NAME> structures and the 54corresponding B<X509_NAME> functions are typically used to 55create and add new entries in a single operation. 56 57The arguments of these functions support similar options to the similarly 58named ones of the corresponding B<X509_NAME> functions such as 59X509_NAME_add_entry_by_txt(). So for example B<type> can be set to 60B<MBSTRING_ASC> but in the case of X509_set_data() the field name must be 61set first so the relevant field information can be looked up internally. 62 63=head1 RETURN VALUES 64 65=head1 SEE ALSO 66 67L<ERR_get_error(3)|ERR_get_error(3)>, L<d2i_X509_NAME(3)|d2i_X509_NAME(3)>, 68L<OBJ_nid2obj(3)|OBJ_nid2obj(3)> 69 70=head1 HISTORY 71 72TBA 73 74=cut 75