diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/libcrypto/man/BIO_ctrl.3 | 5 | ||||
-rw-r--r-- | src/lib/libcrypto/man/BIO_meth_new.3 | 269 | ||||
-rw-r--r-- | src/lib/libcrypto/man/BIO_new.3 | 5 | ||||
-rw-r--r-- | src/lib/libcrypto/man/BIO_read.3 | 5 | ||||
-rw-r--r-- | src/lib/libcrypto/man/Makefile | 3 |
5 files changed, 280 insertions, 7 deletions
diff --git a/src/lib/libcrypto/man/BIO_ctrl.3 b/src/lib/libcrypto/man/BIO_ctrl.3 index 7d1c5da600..d4392dd3d2 100644 --- a/src/lib/libcrypto/man/BIO_ctrl.3 +++ b/src/lib/libcrypto/man/BIO_ctrl.3 | |||
@@ -1,4 +1,4 @@ | |||
1 | .\" $OpenBSD: BIO_ctrl.3,v 1.7 2017/08/01 14:57:03 schwarze Exp $ | 1 | .\" $OpenBSD: BIO_ctrl.3,v 1.8 2018/02/17 23:24:38 schwarze Exp $ |
2 | .\" OpenSSL b055fceb Thu Oct 20 09:56:18 2016 +0100 | 2 | .\" OpenSSL b055fceb Thu Oct 20 09:56:18 2016 +0100 |
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,7 +48,7 @@ | |||
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: August 1 2017 $ | 51 | .Dd $Mdocdate: February 17 2018 $ |
52 | .Dt BIO_CTRL 3 | 52 | .Dt BIO_CTRL 3 |
53 | .Os | 53 | .Os |
54 | .Sh NAME | 54 | .Sh NAME |
@@ -308,6 +308,7 @@ Source/sink BIOs return an 0 if they do not recognize the | |||
308 | .Fn BIO_ctrl | 308 | .Fn BIO_ctrl |
309 | operation. | 309 | operation. |
310 | .Sh SEE ALSO | 310 | .Sh SEE ALSO |
311 | .Xr BIO_meth_new 3 , | ||
311 | .Xr BIO_new 3 | 312 | .Xr BIO_new 3 |
312 | .Sh BUGS | 313 | .Sh BUGS |
313 | Some of the return values are ambiguous and care should be taken. | 314 | Some of the return values are ambiguous and care should be taken. |
diff --git a/src/lib/libcrypto/man/BIO_meth_new.3 b/src/lib/libcrypto/man/BIO_meth_new.3 new file mode 100644 index 0000000000..d50b7ffc76 --- /dev/null +++ b/src/lib/libcrypto/man/BIO_meth_new.3 | |||
@@ -0,0 +1,269 @@ | |||
1 | .\" $OpenBSD: BIO_meth_new.3,v 1.1 2018/02/17 23:24:38 schwarze Exp $ | ||
2 | .\" selective merge up to: OpenSSL 61f805c1 Jan 16 01:01:46 2018 +0800 | ||
3 | .\" | ||
4 | .\" This file is a derived work. | ||
5 | .\" The changes are covered by the following Copyright and license: | ||
6 | .\" | ||
7 | .\" Copyright (c) 2018 Ingo Schwarze <schwarze@openbsd.org> | ||
8 | .\" | ||
9 | .\" Permission to use, copy, modify, and distribute this software for any | ||
10 | .\" purpose with or without fee is hereby granted, provided that the above | ||
11 | .\" copyright notice and this permission notice appear in all copies. | ||
12 | .\" | ||
13 | .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES | ||
14 | .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF | ||
15 | .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR | ||
16 | .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES | ||
17 | .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN | ||
18 | .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF | ||
19 | .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | ||
20 | .\" | ||
21 | .\" The original file was written by Matt Caswell <matt@openssl.org> | ||
22 | .\" Copyright (c) 2016 The OpenSSL Project. All rights reserved. | ||
23 | .\" | ||
24 | .\" Redistribution and use in source and binary forms, with or without | ||
25 | .\" modification, are permitted provided that the following conditions | ||
26 | .\" are met: | ||
27 | .\" | ||
28 | .\" 1. Redistributions of source code must retain the above copyright | ||
29 | .\" notice, this list of conditions and the following disclaimer. | ||
30 | .\" | ||
31 | .\" 2. Redistributions in binary form must reproduce the above copyright | ||
32 | .\" notice, this list of conditions and the following disclaimer in | ||
33 | .\" the documentation and/or other materials provided with the | ||
34 | .\" distribution. | ||
35 | .\" | ||
36 | .\" 3. All advertising materials mentioning features or use of this | ||
37 | .\" software must display the following acknowledgment: | ||
38 | .\" "This product includes software developed by the OpenSSL Project | ||
39 | .\" for use in the OpenSSL Toolkit. (http://www.openssl.org/)" | ||
40 | .\" | ||
41 | .\" 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to | ||
42 | .\" endorse or promote products derived from this software without | ||
43 | .\" prior written permission. For written permission, please contact | ||
44 | .\" openssl-core@openssl.org. | ||
45 | .\" | ||
46 | .\" 5. Products derived from this software may not be called "OpenSSL" | ||
47 | .\" nor may "OpenSSL" appear in their names without prior written | ||
48 | .\" permission of the OpenSSL Project. | ||
49 | .\" | ||
50 | .\" 6. Redistributions of any form whatsoever must retain the following | ||
51 | .\" acknowledgment: | ||
52 | .\" "This product includes software developed by the OpenSSL Project | ||
53 | .\" for use in the OpenSSL Toolkit (http://www.openssl.org/)" | ||
54 | .\" | ||
55 | .\" THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY | ||
56 | .\" EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
57 | .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR | ||
58 | .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR | ||
59 | .\" ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
60 | .\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT | ||
61 | .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
62 | .\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) | ||
63 | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, | ||
64 | .\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
65 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | ||
66 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. | ||
67 | .\" | ||
68 | .Dd $Mdocdate: February 17 2018 $ | ||
69 | .Dt BIO_METH_NEW 3 | ||
70 | .Os | ||
71 | .Sh NAME | ||
72 | .Nm BIO_meth_new , | ||
73 | .Nm BIO_meth_free , | ||
74 | .Nm BIO_meth_set_write , | ||
75 | .Nm BIO_meth_set_read , | ||
76 | .Nm BIO_meth_set_puts , | ||
77 | .Nm BIO_meth_set_ctrl , | ||
78 | .Nm BIO_meth_set_create , | ||
79 | .Nm BIO_meth_set_destroy | ||
80 | .Nd manipulate BIO_METHOD structures | ||
81 | .Sh SYNOPSIS | ||
82 | .In openssl/bio.h | ||
83 | .Ft BIO_METHOD * | ||
84 | .Fo BIO_meth_new | ||
85 | .Fa "int type" | ||
86 | .Fa "const char *name" | ||
87 | .Fc | ||
88 | .Ft void | ||
89 | .Fo BIO_meth_free | ||
90 | .Fa "BIO_METHOD *biom" | ||
91 | .Fc | ||
92 | .Ft int | ||
93 | .Fo BIO_meth_set_write | ||
94 | .Fa "BIO_METHOD *biom" | ||
95 | .Fa "int (*write)(BIO *, const char *, int)" | ||
96 | .Fc | ||
97 | .Ft int | ||
98 | .Fo BIO_meth_set_read | ||
99 | .Fa "BIO_METHOD *biom" | ||
100 | .Fa "int (*read)(BIO *, char *, int)" | ||
101 | .Fc | ||
102 | .Ft int | ||
103 | .Fo BIO_meth_set_puts | ||
104 | .Fa "BIO_METHOD *biom" | ||
105 | .Fa "int (*puts)(BIO *, const char *)" | ||
106 | .Fc | ||
107 | .Ft int | ||
108 | .Fo BIO_meth_set_ctrl | ||
109 | .Fa "BIO_METHOD *biom" | ||
110 | .Fa "long (*ctrl)(BIO *, int, long, void *)" | ||
111 | .Fc | ||
112 | .Ft int | ||
113 | .Fo BIO_meth_set_create | ||
114 | .Fa "BIO_METHOD *biom" | ||
115 | .Fa "int (*create)(BIO *)" | ||
116 | .Fc | ||
117 | .Ft int | ||
118 | .Fo BIO_meth_set_destroy | ||
119 | .Fa "BIO_METHOD *biom" | ||
120 | .Fa "int (*destroy)(BIO *)" | ||
121 | .Fc | ||
122 | .Sh DESCRIPTION | ||
123 | The | ||
124 | .Vt BIO_METHOD | ||
125 | structure stores function pointers implementing a | ||
126 | .Vt BIO | ||
127 | type. | ||
128 | See | ||
129 | .Xr BIO_new 3 | ||
130 | for more information about | ||
131 | .Vt BIO | ||
132 | objects. | ||
133 | .Pp | ||
134 | .Fn BIO_meth_new | ||
135 | creates a new | ||
136 | .Vt BIO_METHOD | ||
137 | structure. | ||
138 | It requires a unique integer | ||
139 | .Fa type . | ||
140 | The | ||
141 | .Fa name | ||
142 | pointer is stored in the structure and will not be freed by | ||
143 | .Fn BIO_meth_free . | ||
144 | .Pp | ||
145 | The standard BIO types are listed in | ||
146 | .In openssl/bio.h . | ||
147 | Some examples include | ||
148 | .Dv BIO_TYPE_BUFFER | ||
149 | and | ||
150 | .Dv BIO_TYPE_CIPHER . | ||
151 | The | ||
152 | .Fa type | ||
153 | of filter BIOs should have the | ||
154 | .Dv BIO_TYPE_FILTER | ||
155 | bit set. | ||
156 | Source/sink BIOs should have the | ||
157 | .Dv BIO_TYPE_SOURCE_SINK | ||
158 | bit set. | ||
159 | File descriptor based BIOs (e.g. socket, fd, connect, accept etc.\&) | ||
160 | should additionally have the | ||
161 | .Dv BIO_TYPE_DESCRIPTOR | ||
162 | bit set. | ||
163 | See | ||
164 | .Xr BIO_find_type 3 | ||
165 | for more information. | ||
166 | .Pp | ||
167 | .Fn BIO_meth_free | ||
168 | is an alias for | ||
169 | .Xr free 3 . | ||
170 | .Pp | ||
171 | .Fn BIO_meth_set_write | ||
172 | and | ||
173 | .Fn BIO_meth_set_read | ||
174 | set the functions | ||
175 | .Fa write | ||
176 | and | ||
177 | .Fa read | ||
178 | used for writing and reading arbitrary length data to and from the | ||
179 | .Vt BIO . | ||
180 | These functions are called from | ||
181 | .Xr BIO_write 3 | ||
182 | and | ||
183 | .Xr BIO_read 3 , | ||
184 | respectively. | ||
185 | The parameters and return values of | ||
186 | .Fa write | ||
187 | and | ||
188 | .Fa read | ||
189 | have the same meaning as for | ||
190 | .Xr BIO_write 3 | ||
191 | and | ||
192 | .Xr BIO_read 3 . | ||
193 | .Pp | ||
194 | .Fn BIO_meth_set_puts | ||
195 | sets the function | ||
196 | .Fa puts | ||
197 | used for writing a NUL-terminated string to the | ||
198 | .Vt BIO . | ||
199 | This function is called from | ||
200 | .Xr BIO_puts 3 . | ||
201 | The parameters and the return value of | ||
202 | .Fa puts | ||
203 | have the same meaning as for | ||
204 | .Xr BIO_puts 3 . | ||
205 | .Pp | ||
206 | .Fn BIO_meth_set_ctrl | ||
207 | sets the function | ||
208 | .Fa ctrl | ||
209 | used for processing control messages in the | ||
210 | .Vt BIO . | ||
211 | This function is called from | ||
212 | .Xr BIO_ctrl 3 . | ||
213 | The parameters and return value of | ||
214 | .Fa ctrl | ||
215 | have the same meaning as for | ||
216 | .Xr BIO_ctrl 3 . | ||
217 | .Pp | ||
218 | .Fn BIO_meth_set_create | ||
219 | sets a function | ||
220 | .Fa create | ||
221 | used while initializing a new instance of the | ||
222 | .Vt BIO . | ||
223 | This function is called from | ||
224 | .Xr BIO_new 3 . | ||
225 | The | ||
226 | .Xr BIO_new 3 | ||
227 | function allocates the memory for the new | ||
228 | .Vt BIO , | ||
229 | and a pointer to this newly allocated structure is passed | ||
230 | as the parameter to | ||
231 | .Fa create . | ||
232 | .Pp | ||
233 | .Fn BIO_meth_set_destroy | ||
234 | sets a function | ||
235 | .Fa destroy | ||
236 | used while destroying an instance of a | ||
237 | .Vt BIO . | ||
238 | This function is called from | ||
239 | .Xr BIO_free 3 . | ||
240 | A pointer to the | ||
241 | .Vt BIO | ||
242 | to be destroyed is passed as the parameter. | ||
243 | The | ||
244 | .Fa destroy | ||
245 | function is intended to perform clean-up specific to the | ||
246 | .Vt BIO | ||
247 | .Fa type . | ||
248 | The memory for the | ||
249 | .Vt BIO | ||
250 | itself must not be freed by this function. | ||
251 | .Sh RETURN VALUES | ||
252 | .Fn BIO_meth_new | ||
253 | returns the new | ||
254 | .Vt BIO_METHOD | ||
255 | structure or | ||
256 | .Dv NULL | ||
257 | if an error occurs. | ||
258 | .Pp | ||
259 | The | ||
260 | .Fn BIO_meth_set_* | ||
261 | functions return 1 on success or 0 on error. | ||
262 | Currently, they cannot fail. | ||
263 | .Sh SEE ALSO | ||
264 | .Xr BIO_ctrl 3 , | ||
265 | .Xr BIO_find_type 3 , | ||
266 | .Xr BIO_new 3 , | ||
267 | .Xr BIO_read 3 | ||
268 | .Sh HISTORY | ||
269 | These functions first appeared in OpenSSL 1.1.0. | ||
diff --git a/src/lib/libcrypto/man/BIO_new.3 b/src/lib/libcrypto/man/BIO_new.3 index 356986d76d..cdf15278bf 100644 --- a/src/lib/libcrypto/man/BIO_new.3 +++ b/src/lib/libcrypto/man/BIO_new.3 | |||
@@ -1,4 +1,4 @@ | |||
1 | .\" $OpenBSD: BIO_new.3,v 1.8 2017/03/25 17:15:59 schwarze Exp $ | 1 | .\" $OpenBSD: BIO_new.3,v 1.9 2018/02/17 23:24:38 schwarze Exp $ |
2 | .\" OpenSSL doc/man3/BIO_new.pod ca3a82c3 Mar 25 11:31:18 2015 -0400 | 2 | .\" OpenSSL doc/man3/BIO_new.pod ca3a82c3 Mar 25 11:31:18 2015 -0400 |
3 | .\" OpenSSL doc/man7/bio.pod a9c85cea Nov 11 09:33:55 2016 +0100 | 3 | .\" OpenSSL doc/man7/bio.pod a9c85cea Nov 11 09:33:55 2016 +0100 |
4 | .\" | 4 | .\" |
@@ -49,7 +49,7 @@ | |||
49 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | 49 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED |
50 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. | 50 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. |
51 | .\" | 51 | .\" |
52 | .Dd $Mdocdate: March 25 2017 $ | 52 | .Dd $Mdocdate: February 17 2018 $ |
53 | .Dt BIO_NEW 3 | 53 | .Dt BIO_NEW 3 |
54 | .Os | 54 | .Os |
55 | .Sh NAME | 55 | .Sh NAME |
@@ -192,6 +192,7 @@ Create a memory BIO: | |||
192 | .Xr BIO_f_ssl 3 , | 192 | .Xr BIO_f_ssl 3 , |
193 | .Xr BIO_find_type 3 , | 193 | .Xr BIO_find_type 3 , |
194 | .Xr BIO_get_ex_new_index 3 , | 194 | .Xr BIO_get_ex_new_index 3 , |
195 | .Xr BIO_meth_new 3 , | ||
195 | .Xr BIO_printf 3 , | 196 | .Xr BIO_printf 3 , |
196 | .Xr BIO_push 3 , | 197 | .Xr BIO_push 3 , |
197 | .Xr BIO_read 3 , | 198 | .Xr BIO_read 3 , |
diff --git a/src/lib/libcrypto/man/BIO_read.3 b/src/lib/libcrypto/man/BIO_read.3 index 2da3728237..a58c1fa5ff 100644 --- a/src/lib/libcrypto/man/BIO_read.3 +++ b/src/lib/libcrypto/man/BIO_read.3 | |||
@@ -1,4 +1,4 @@ | |||
1 | .\" $OpenBSD: BIO_read.3,v 1.5 2016/12/06 14:45:08 schwarze Exp $ | 1 | .\" $OpenBSD: BIO_read.3,v 1.6 2018/02/17 23:24:38 schwarze Exp $ |
2 | .\" OpenSSL 99d63d46 Oct 26 13:56:48 2016 -0400 | 2 | .\" OpenSSL 99d63d46 Oct 26 13:56:48 2016 -0400 |
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,7 +48,7 @@ | |||
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 6 2016 $ | 51 | .Dd $Mdocdate: February 17 2018 $ |
52 | .Dt BIO_READ 3 | 52 | .Dt BIO_READ 3 |
53 | .Os | 53 | .Os |
54 | .Sh NAME | 54 | .Sh NAME |
@@ -165,5 +165,6 @@ In particular when the source/sink is non-blocking or of a certain type | |||
165 | it may merely be an indication that no data is currently available and that | 165 | it may merely be an indication that no data is currently available and that |
166 | the application should retry the operation later. | 166 | the application should retry the operation later. |
167 | .Sh SEE ALSO | 167 | .Sh SEE ALSO |
168 | .Xr BIO_meth_new 3 , | ||
168 | .Xr BIO_new 3 , | 169 | .Xr BIO_new 3 , |
169 | .Xr BIO_should_retry 3 | 170 | .Xr BIO_should_retry 3 |
diff --git a/src/lib/libcrypto/man/Makefile b/src/lib/libcrypto/man/Makefile index 77a6519685..431285c7e0 100644 --- a/src/lib/libcrypto/man/Makefile +++ b/src/lib/libcrypto/man/Makefile | |||
@@ -1,4 +1,4 @@ | |||
1 | # $OpenBSD: Makefile,v 1.130 2018/02/17 16:59:48 schwarze Exp $ | 1 | # $OpenBSD: Makefile,v 1.131 2018/02/17 23:24:38 schwarze Exp $ |
2 | 2 | ||
3 | .include <bsd.own.mk> | 3 | .include <bsd.own.mk> |
4 | 4 | ||
@@ -26,6 +26,7 @@ MAN= \ | |||
26 | BIO_f_null.3 \ | 26 | BIO_f_null.3 \ |
27 | BIO_find_type.3 \ | 27 | BIO_find_type.3 \ |
28 | BIO_get_ex_new_index.3 \ | 28 | BIO_get_ex_new_index.3 \ |
29 | BIO_meth_new.3 \ | ||
29 | BIO_new.3 \ | 30 | BIO_new.3 \ |
30 | BIO_printf.3 \ | 31 | BIO_printf.3 \ |
31 | BIO_push.3 \ | 32 | BIO_push.3 \ |