diff options
Diffstat (limited to 'src/lib/libcrypto/man/ASIdentifiers_new.3')
-rw-r--r-- | src/lib/libcrypto/man/ASIdentifiers_new.3 | 129 |
1 files changed, 129 insertions, 0 deletions
diff --git a/src/lib/libcrypto/man/ASIdentifiers_new.3 b/src/lib/libcrypto/man/ASIdentifiers_new.3 new file mode 100644 index 0000000000..828cda6ec6 --- /dev/null +++ b/src/lib/libcrypto/man/ASIdentifiers_new.3 | |||
@@ -0,0 +1,129 @@ | |||
1 | .\" $OpenBSD: ASIdentifiers_new.3,v 1.1 2023/09/25 01:14:34 tb Exp $ | ||
2 | .\" | ||
3 | .\" Copyright (c) 2021 Theo Buehler <tb@openbsd.org> | ||
4 | .\" | ||
5 | .\" Permission to use, copy, modify, and distribute this software for any | ||
6 | .\" purpose with or without fee is hereby granted, provided that the above | ||
7 | .\" copyright notice and this permission notice appear in all copies. | ||
8 | .\" | ||
9 | .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
10 | .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
11 | .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
12 | .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
13 | .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
14 | .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
15 | .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
16 | .\" | ||
17 | .Dd $Mdocdate: September 25 2023 $ | ||
18 | .Dt ASIDENTIFIERS_NEW 3 | ||
19 | .Os | ||
20 | .Sh NAME | ||
21 | .Nm ASIdentifiers_new , | ||
22 | .Nm ASIdentifiers_free , | ||
23 | .Nm d2i_ASIdentifiers , | ||
24 | .Nm i2d_ASIdentifiers | ||
25 | .Nd X509v3 certificate extension for autonomous system identifier delegation | ||
26 | .Sh SYNOPSIS | ||
27 | .In openssl/x509v3.h | ||
28 | .Ft ASIdentifiers * | ||
29 | .Fo ASIdentifiers_new | ||
30 | .Fa "void" | ||
31 | .Fc | ||
32 | .Ft void | ||
33 | .Fo ASIdentifiers_free | ||
34 | .Fa "ASIdentifiers *asid" | ||
35 | .Fc | ||
36 | .Ft ASIdentifiers * | ||
37 | .Fo d2i_ASIdentifiers | ||
38 | .Fa "ASIdentifiers **asid" | ||
39 | .Fa "const unsigned char **in" | ||
40 | .Fa "long len" | ||
41 | .Fc | ||
42 | .Ft int | ||
43 | .Fo i2d_ASIdentifiers | ||
44 | .Fa "ASIdentifiers *asid" | ||
45 | .Fa "unsigned char **out" | ||
46 | .Fc | ||
47 | .Sh DESCRIPTION | ||
48 | RFC 3779 defines two X.509v3 certificate extensions that allow the | ||
49 | delegation of | ||
50 | IP address blocks and autonomous system (AS) identifiers | ||
51 | from the issuer to the subject of the certificate. | ||
52 | An | ||
53 | .Vt ASIdentifiers | ||
54 | object contains collections of individual AS numbers and | ||
55 | ranges of AS numbers to be delegated. | ||
56 | .Pp | ||
57 | .Fn ASIdentifiers_new | ||
58 | allocates and initializes a new, empty | ||
59 | .Vt ASIdentifiers | ||
60 | object that can be populated with | ||
61 | .Xr X509v3_asid_add_id_or_range 3 . | ||
62 | .Pp | ||
63 | .Fn ASIdentifiers_free | ||
64 | frees | ||
65 | .Fa asid | ||
66 | including any data contained in it. | ||
67 | If | ||
68 | .Fa asid | ||
69 | is | ||
70 | .Dv NULL , | ||
71 | no action occurs. | ||
72 | .Pp | ||
73 | .Fn d2i_ASIdentifiers | ||
74 | and | ||
75 | .Fn i2d_ASIdentifiers | ||
76 | decode and encode ASN.1 | ||
77 | .Vt ASIdentifiers | ||
78 | structures as defined in RFC 3779, section 3.2.3.1. | ||
79 | For details about the semantics, examples, caveats, and bugs, see | ||
80 | .Xr ASN1_item_d2i 3 . | ||
81 | In order for the encoding produced by | ||
82 | .Fn d2i_ASIdentifiers | ||
83 | to conform to RFC 3779, | ||
84 | .Fa asid | ||
85 | must be in | ||
86 | .Dq canonical form , | ||
87 | see | ||
88 | .Xr X509v3_asid_canonize 3 . | ||
89 | .Sh RETURN VALUES | ||
90 | .Fn ASIdentifiers_new | ||
91 | returns a new | ||
92 | .Vt ASIdentifiers | ||
93 | object or | ||
94 | .Dv NULL | ||
95 | on if an error occurs. | ||
96 | .Pp | ||
97 | .Fn d2i_ASIdentifiers | ||
98 | returns an | ||
99 | .Vt ASIdentifiers | ||
100 | object or | ||
101 | .Dv NULL | ||
102 | on if a decoding or memory allocation error occurs. | ||
103 | .Pp | ||
104 | .Fn i2d_ASIdentifiers | ||
105 | returns the number of bytes successfully encoded | ||
106 | or a value <= 0 if an error occurs. | ||
107 | .Sh SEE ALSO | ||
108 | .Xr crypto 3 , | ||
109 | .Xr X509_new 3 , | ||
110 | .Xr X509v3_asid_add_id_or_range 3 , | ||
111 | .Xr X509v3_asid_is_canonical 3 | ||
112 | .Sh STANDARDS | ||
113 | RFC 3779: X.509 Extensions for IP Addresses and AS Identifiers: | ||
114 | .Bl -dash -compact | ||
115 | .It | ||
116 | section 3: Autonomous System Identifier Delegation Extension | ||
117 | .El | ||
118 | .Pp | ||
119 | RFC 7020: The Internet Numbers Registry System | ||
120 | .Pp | ||
121 | RFC 7249: Internet Numbers Registries | ||
122 | .Sh HISTORY | ||
123 | These functions first appeared in OpenSSL 0.9.8e | ||
124 | and have been available since | ||
125 | .Ox 7.1 . | ||
126 | .Sh BUGS | ||
127 | There are no corresponding functions for the RFC 3779 | ||
128 | IP address blocks delegation extension represented by | ||
129 | .Vt IPAddrBlocks . | ||