summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/man/X509_new.3
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/lib/libcrypto/man/X509_new.335
1 files changed, 26 insertions, 9 deletions
diff --git a/src/lib/libcrypto/man/X509_new.3 b/src/lib/libcrypto/man/X509_new.3
index 605d1db7be..6520aaf477 100644
--- a/src/lib/libcrypto/man/X509_new.3
+++ b/src/lib/libcrypto/man/X509_new.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: X509_new.3,v 1.6 2016/12/12 22:02:55 jmc Exp $ 1.\" $OpenBSD: X509_new.3,v 1.7 2016/12/22 13:05:59 schwarze Exp $
2.\" OpenSSL 3a59ad98 Dec 11 00:36:06 2015 +0000 2.\" OpenSSL 3a59ad98 Dec 11 00:36:06 2015 +0000
3.\" 3.\"
4.\" This file was written by Dr. Stephen Henson <steve@openssl.org>. 4.\" This file was written by Dr. Stephen Henson <steve@openssl.org>.
@@ -48,14 +48,14 @@
48.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED 48.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
49.\" OF THE POSSIBILITY OF SUCH DAMAGE. 49.\" OF THE POSSIBILITY OF SUCH DAMAGE.
50.\" 50.\"
51.Dd $Mdocdate: December 12 2016 $ 51.Dd $Mdocdate: December 22 2016 $
52.Dt X509_NEW 3 52.Dt X509_NEW 3
53.Os 53.Os
54.Sh NAME 54.Sh NAME
55.Nm X509_new , 55.Nm X509_new ,
56.Nm X509_free , 56.Nm X509_free ,
57.Nm X509_up_ref 57.Nm X509_up_ref
58.Nd X509 certificate ASN.1 allocation functions 58.Nd X.509 certificate object
59.Sh SYNOPSIS 59.Sh SYNOPSIS
60.In openssl/x509.h 60.In openssl/x509.h
61.Ft X509 * 61.Ft X509 *
@@ -69,12 +69,14 @@
69.Fa "X509 *a" 69.Fa "X509 *a"
70.Fc 70.Fc
71.Sh DESCRIPTION 71.Sh DESCRIPTION
72The X509 ASN.1 allocation routines allocate and free an
73.Vt X509
74structure, which represents an X509 certificate.
75.Pp
76.Fn X509_new 72.Fn X509_new
77allocates and initializes an X509 structure with reference count 1. 73allocates and initializes an empty
74.Vt X509
75object with reference count 1.
76It represents an ASN.1 Certificate structure
77defined in RFC 5280 section 4.1.
78It can hold a public key together with information about the person,
79organization, device, or function the associated private key belongs to.
78.Pp 80.Pp
79.Fn X509_free 81.Fn X509_free
80decrements the reference count of the 82decrements the reference count of the
@@ -95,6 +97,11 @@ This function is useful if a certificate structure is being used
95by several different operations each of which will free it up after 97by several different operations each of which will free it up after
96use: this avoids the need to duplicate the entire certificate 98use: this avoids the need to duplicate the entire certificate
97structure. 99structure.
100.Pp
101The object
102.Vt X509_INFO ,
103which can hold a certificate, the corresponding private key,
104and a certificate revocation list, is not yet documented.
98.Sh RETURN VALUES 105.Sh RETURN VALUES
99If the allocation fails, 106If the allocation fails,
100.Fn X509_new 107.Fn X509_new
@@ -107,8 +114,18 @@ Otherwise it returns a pointer to the newly allocated structure.
107.Fn X509_up_ref 114.Fn X509_up_ref
108returns 1 for success or 0 for failure. 115returns 1 for success or 0 for failure.
109.Sh SEE ALSO 116.Sh SEE ALSO
117.Xr crypto 3 ,
110.Xr d2i_X509 3 , 118.Xr d2i_X509 3 ,
111.Xr ERR_get_error 3 119.Xr ERR_get_error 3 ,
120.Xr X509_ALGOR_new 3 ,
121.Xr X509_CRL_new 3 ,
122.Xr X509_EXTENSION_new 3 ,
123.Xr X509_NAME_new 3 ,
124.Xr X509_REQ_new 3 ,
125.Xr X509_SIG_new 3
126.Sh STANDARDS
127RFC 5280: Internet X.509 Public Key Infrastructure Certificate and
128Certificate Revocation List (CRL) Profile
112.Sh HISTORY 129.Sh HISTORY
113.Fn X509_new 130.Fn X509_new
114and 131and