GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
X509_REQ_ADD1_ATTR(3) FreeBSD Library Functions Manual X509_REQ_ADD1_ATTR(3)

X509_REQ_add1_attr, X509_REQ_add1_attr_by_OBJ, X509_REQ_add1_attr_by_NID, X509_REQ_add1_attr_by_txt, X509_REQ_delete_attr, X509_REQ_get_attr, X509_REQ_get_attr_count, X509_REQ_get_attr_by_OBJ, X509_REQ_get_attr_by_NID
X.501 Attributes of PKCS#10 certification requests

#include <openssl/x509.h>

int
X509_REQ_add1_attr(X509_REQ *req, X509_ATTRIBUTE *attr);

int
X509_REQ_add1_attr_by_OBJ(X509_REQ *req, const ASN1_OBJECT *obj, int type, const unsigned char *data, int len);

int
X509_REQ_add1_attr_by_NID(X509_REQ *req, int nid, int type, const unsigned char *data, int len);

int
X509_REQ_add1_attr_by_txt(X509_REQ *req, const char *name, int type, const unsigned char *data, int len);

X509_ATTRIBUTE *
X509_REQ_delete_attr(X509_REQ *req, int index);

X509_ATTRIBUTE *
X509_REQ_get_attr(const X509_REQ *req, int index);

int
X509_REQ_get_attr_count(const X509_REQ *req);

int
X509_REQ_get_attr_by_OBJ(const X509_REQ *req, const ASN1_OBJECT *obj, int start_after);

int
X509_REQ_get_attr_by_NID(const X509_REQ *req, int nid, int start_after);

These functions support associating an array of X.501 Attributes with a PKCS#10 certification request.

X509_REQ_add1_attr() appends a deep copy of the attr using X509at_add1_attr(3).

X509_REQ_add1_attr_by_OBJ(), X509_REQ_add1_attr_by_NID(), and X509_REQ_add1_attr_by_txt() create a new X.501 Attribute object using X509_ATTRIBUTE_create_by_OBJ(3), X509_ATTRIBUTE_create_by_NID(3), or X509_ATTRIBUTE_create_by_txt(3), respectively, and append it using X509at_add1_attr(3).

X509_REQ_delete_attr() deletes the attribute with the zero-based index using X509at_delete_attr(3).

X509_REQ_get_attr() returns the attribute with the zero-based index using X509at_get_attr(3).

X509_REQ_get_attr_count() returns the number of attributes currently associated with req using X509at_get_attr_count(3).

X509_REQ_get_attr_by_OBJ() and X509_REQ_get_attr_by_NID() search for an attribute of the type obj or nid using X509at_get_attr_by_OBJ(3) or X509at_get_attr_by_NID(3), respectively.

X509_REQ_add1_attr(), X509_REQ_add1_attr_by_OBJ(), X509_REQ_add1_attr_by_NID(), and X509_REQ_add1_attr_by_txt() return 1 for success or 0 for failure.

X509_REQ_delete_attr() and X509_REQ_get_attr() return the deleted or requested attribute or NULL if the requested index is negative or greater than or equal to the current number of attributes associated with req.

X509_REQ_get_attr_count() returns the current number of attributes.

X509_REQ_get_attr_by_OBJ() and X509_REQ_get_attr_by_NID() return the index of the first attribute that has an index greater than start_after and a type matching obj or nid, respectively, or -1 on failure. In addition, X509_REQ_get_attr_by_NID() returns -2 if OBJ_nid2obj(3) fails on the requested nid.

OBJ_nid2obj(3), X509_ATTRIBUTE_create_by_OBJ(3), X509_ATTRIBUTE_new(3), X509_REQ_new(3), X509at_add1_attr(3), X509at_get_attr(3)

These functions first appeared in OpenSSL 0.9.5 and have been available since OpenBSD 2.7.
October 26, 2021 FreeBSD 13.1-RELEASE

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.