Current Path : /usr/opt/openssl11/share/doc/openssl/html/man3/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/opt/openssl11/share/doc/openssl/html/man3/X509_NAME_ENTRY_create_by_NID.html |
<?xml version="1.0" ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>X509_NAME_ENTRY_get_object</title> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <link rev="made" href="mailto:root@hsxx.drive.ne.jp" /> </head> <body style="background-color: white"> <!-- INDEX BEGIN --> <div name="index"> <p><a name="__index__"></a></p> <ul> <li><a href="#name">NAME</a></li> <li><a href="#synopsis">SYNOPSIS</a></li> <li><a href="#description">DESCRIPTION</a></li> <li><a href="#notes">NOTES</a></li> <li><a href="#return_values">RETURN VALUES</a></li> <li><a href="#see_also">SEE ALSO</a></li> <li><a href="#copyright">COPYRIGHT</a></li> </ul> <hr name="index" /> </div> <!-- INDEX END --> <p> </p> <hr /> <h1><a name="name">NAME</a></h1> <p>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_OBJ - X509_NAME_ENTRY utility functions</p> <p> </p> <hr /> <h1><a name="synopsis">SYNOPSIS</a></h1> <pre> #include <openssl/x509.h></pre> <pre> ASN1_OBJECT *X509_NAME_ENTRY_get_object(const X509_NAME_ENTRY *ne); ASN1_STRING *X509_NAME_ENTRY_get_data(const X509_NAME_ENTRY *ne);</pre> <pre> int X509_NAME_ENTRY_set_object(X509_NAME_ENTRY *ne, const ASN1_OBJECT *obj); int X509_NAME_ENTRY_set_data(X509_NAME_ENTRY *ne, int type, const unsigned char *bytes, int len);</pre> <pre> X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_txt(X509_NAME_ENTRY **ne, const char *field, int type, const unsigned char *bytes, int len); X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_NID(X509_NAME_ENTRY **ne, int nid, int type, const unsigned char *bytes, int len); X509_NAME_ENTRY *X509_NAME_ENTRY_create_by_OBJ(X509_NAME_ENTRY **ne, const ASN1_OBJECT *obj, int type, const unsigned char *bytes, int len);</pre> <p> </p> <hr /> <h1><a name="description">DESCRIPTION</a></h1> <p>X509_NAME_ENTRY_get_object() retrieves the field name of <strong>ne</strong> in and <strong>ASN1_OBJECT</strong> structure.</p> <p>X509_NAME_ENTRY_get_data() retrieves the field value of <strong>ne</strong> in and <strong>ASN1_STRING</strong> structure.</p> <p>X509_NAME_ENTRY_set_object() sets the field name of <strong>ne</strong> to <strong>obj</strong>.</p> <p>X509_NAME_ENTRY_set_data() sets the field value of <strong>ne</strong> to string type <strong>type</strong> and value determined by <strong>bytes</strong> and <strong>len</strong>.</p> <p>X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_NID() and X509_NAME_ENTRY_create_by_OBJ() create and return an <strong>X509_NAME_ENTRY</strong> structure.</p> <p> </p> <hr /> <h1><a name="notes">NOTES</a></h1> <p>X509_NAME_ENTRY_get_object() and X509_NAME_ENTRY_get_data() can be used to examine an <strong>X509_NAME_ENTRY</strong> function as returned by X509_NAME_get_entry() for example.</p> <p>X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_OBJ(), X509_NAME_ENTRY_create_by_NID() and X509_NAME_ENTRY_set_data() are seldom used in practice because <strong>X509_NAME_ENTRY</strong> structures are almost always part of <strong>X509_NAME</strong> structures and the corresponding <strong>X509_NAME</strong> functions are typically used to create and add new entries in a single operation.</p> <p>The arguments of these functions support similar options to the similarly named ones of the corresponding <strong>X509_NAME</strong> functions such as X509_NAME_add_entry_by_txt(). So for example <strong>type</strong> can be set to <strong>MBSTRING_ASC</strong> but in the case of X509_set_data() the field name must be set first so the relevant field information can be looked up internally.</p> <p> </p> <hr /> <h1><a name="return_values">RETURN VALUES</a></h1> <p>X509_NAME_ENTRY_get_object() returns a valid <strong>ASN1_OBJECT</strong> structure if it is set or NULL if an error occurred.</p> <p>X509_NAME_ENTRY_get_data() returns a valid <strong>ASN1_STRING</strong> structure if it is set or NULL if an error occurred.</p> <p>X509_NAME_ENTRY_set_object() and X509_NAME_ENTRY_set_data() return 1 on success or 0 on error.</p> <p>X509_NAME_ENTRY_create_by_txt(), X509_NAME_ENTRY_create_by_NID() and X509_NAME_ENTRY_create_by_OBJ() return a valid <strong>X509_NAME_ENTRY</strong> on success or NULL if an error occurred.</p> <p> </p> <hr /> <h1><a name="see_also">SEE ALSO</a></h1> <p><em>ERR_get_error(3)</em>, <em>d2i_X509_NAME(3)</em>, <em>OBJ_nid2obj(3)</em></p> <p> </p> <hr /> <h1><a name="copyright">COPYRIGHT</a></h1> <p>Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved.</p> <p>Licensed under the OpenSSL license (the "License"). You may not use this file except in compliance with the License. You can obtain a copy in the file LICENSE in the source distribution or at <a href="https://www.openssl.org/source/license.html">https://www.openssl.org/source/license.html</a>.</p> </body> </html>