diff options
author | schwarze <> | 2020-09-20 10:20:44 +0000 |
---|---|---|
committer | schwarze <> | 2020-09-20 10:20:44 +0000 |
commit | 0a7afeae06c69c09fad3e24ba5446736b204958d (patch) | |
tree | ffd4a2f9130eb4579ca47dcacc98f10e99e77190 | |
parent | 2c31c1e37e57201209afec96b54cdeb030f05c73 (diff) | |
download | openbsd-0a7afeae06c69c09fad3e24ba5446736b204958d.tar.gz openbsd-0a7afeae06c69c09fad3e24ba5446736b204958d.tar.bz2 openbsd-0a7afeae06c69c09fad3e24ba5446736b204958d.zip |
Document the public function SSL_set_SSL_CTX(3) from scratch,
which is undocumented in OpenSSL but mentioned in passing in one
OpenSSL manual page, and which was recently mentioned by jsing@ when
working on SSL_set_ciphersuites(3).
With corrections from and OK inoguchi@.
-rw-r--r-- | src/lib/libssl/man/Makefile | 3 | ||||
-rw-r--r-- | src/lib/libssl/man/SSL_set_SSL_CTX.3 | 67 | ||||
-rw-r--r-- | src/lib/libssl/man/ssl.3 | 5 |
3 files changed, 72 insertions, 3 deletions
diff --git a/src/lib/libssl/man/Makefile b/src/lib/libssl/man/Makefile index 0ea04a3077..f8e5cffd59 100644 --- a/src/lib/libssl/man/Makefile +++ b/src/lib/libssl/man/Makefile | |||
@@ -1,4 +1,4 @@ | |||
1 | # $OpenBSD: Makefile,v 1.67 2020/09/17 08:04:22 schwarze Exp $ | 1 | # $OpenBSD: Makefile,v 1.68 2020/09/20 10:20:43 schwarze Exp $ |
2 | 2 | ||
3 | .include <bsd.own.mk> | 3 | .include <bsd.own.mk> |
4 | 4 | ||
@@ -104,6 +104,7 @@ MAN = BIO_f_ssl.3 \ | |||
104 | SSL_session_reused.3 \ | 104 | SSL_session_reused.3 \ |
105 | SSL_set1_host.3 \ | 105 | SSL_set1_host.3 \ |
106 | SSL_set1_param.3 \ | 106 | SSL_set1_param.3 \ |
107 | SSL_set_SSL_CTX.3 \ | ||
107 | SSL_set_bio.3 \ | 108 | SSL_set_bio.3 \ |
108 | SSL_set_connect_state.3 \ | 109 | SSL_set_connect_state.3 \ |
109 | SSL_set_fd.3 \ | 110 | SSL_set_fd.3 \ |
diff --git a/src/lib/libssl/man/SSL_set_SSL_CTX.3 b/src/lib/libssl/man/SSL_set_SSL_CTX.3 new file mode 100644 index 0000000000..567e34f681 --- /dev/null +++ b/src/lib/libssl/man/SSL_set_SSL_CTX.3 | |||
@@ -0,0 +1,67 @@ | |||
1 | .\" $OpenBSD: SSL_set_SSL_CTX.3,v 1.1 2020/09/20 10:20:44 schwarze Exp $ | ||
2 | .\" | ||
3 | .\" Copyright (c) 2020 Ingo Schwarze <schwarze@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 20 2020 $ | ||
18 | .Dt SSL_SET_SSL_CTX 3 | ||
19 | .Os | ||
20 | .Sh NAME | ||
21 | .Nm SSL_set_SSL_CTX | ||
22 | .Nd associate an SSL connection object with a context | ||
23 | .Sh SYNOPSIS | ||
24 | .In openssl/ssl.h | ||
25 | .Ft SSL_CTX * | ||
26 | .Fo SSL_set_SSL_CTX | ||
27 | .Fa "SSL *ssl" | ||
28 | .Fa "SSL_CTX* ctx" | ||
29 | .Fc | ||
30 | .Sh DESCRIPTION | ||
31 | .Fn SSL_set_SSL_CTX | ||
32 | causes | ||
33 | .Fa ssl | ||
34 | to use the context | ||
35 | .Fa ctx | ||
36 | in the future. | ||
37 | .Pp | ||
38 | If | ||
39 | .Fa ctx | ||
40 | is | ||
41 | .Dv NULL , | ||
42 | .Fa ssl | ||
43 | reverts to using the context that it was initially created from with | ||
44 | .Xr SSL_new 3 . | ||
45 | .Pp | ||
46 | If | ||
47 | .Fa ssl | ||
48 | already uses | ||
49 | .Fa ctx , | ||
50 | no action occurs. | ||
51 | .Sh RETURN VALUES | ||
52 | .Fn SSL_set_SSL_CTX | ||
53 | returns an internal pointer to the context that | ||
54 | .Fa ssl | ||
55 | will use after the call, or | ||
56 | .Dv NULL | ||
57 | if memory allocation fails. | ||
58 | .Sh SEE ALSO | ||
59 | .Xr ssl 3 , | ||
60 | .Xr SSL_clear 3 , | ||
61 | .Xr SSL_CTX_new 3 , | ||
62 | .Xr SSL_get_SSL_CTX 3 , | ||
63 | .Xr SSL_new 3 | ||
64 | .Sh HISTORY | ||
65 | .Fn SSL_set_SSL_CTX | ||
66 | first appeared in OpenSSL 0.9.8f and has been available since | ||
67 | .Ox 4.5 . | ||
diff --git a/src/lib/libssl/man/ssl.3 b/src/lib/libssl/man/ssl.3 index 0833a52f86..26596a5f8c 100644 --- a/src/lib/libssl/man/ssl.3 +++ b/src/lib/libssl/man/ssl.3 | |||
@@ -1,4 +1,4 @@ | |||
1 | .\" $OpenBSD: ssl.3,v 1.18 2020/09/18 15:39:37 schwarze Exp $ | 1 | .\" $OpenBSD: ssl.3,v 1.19 2020/09/20 10:20:44 schwarze Exp $ |
2 | .\" full merge up to: OpenSSL e330f55d Nov 11 00:51:04 2016 +0100 | 2 | .\" full merge up to: OpenSSL e330f55d Nov 11 00:51:04 2016 +0100 |
3 | .\" selective merge up to: OpenSSL 322755cc Sep 1 08:40:51 2018 +0800 | 3 | .\" selective merge up to: OpenSSL 322755cc Sep 1 08:40:51 2018 +0800 |
4 | .\" | 4 | .\" |
@@ -51,7 +51,7 @@ | |||
51 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | 51 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED |
52 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. | 52 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. |
53 | .\" | 53 | .\" |
54 | .Dd $Mdocdate: September 18 2020 $ | 54 | .Dd $Mdocdate: September 20 2020 $ |
55 | .Dt SSL 3 | 55 | .Dt SSL 3 |
56 | .Os | 56 | .Os |
57 | .Sh NAME | 57 | .Sh NAME |
@@ -295,6 +295,7 @@ Constructors and destructors: | |||
295 | .Pp | 295 | .Pp |
296 | To change the configuration: | 296 | To change the configuration: |
297 | .Xr SSL_clear 3 , | 297 | .Xr SSL_clear 3 , |
298 | .Xr SSL_set_SSL_CTX 3 , | ||
298 | .Xr SSL_copy_session_id 3 , | 299 | .Xr SSL_copy_session_id 3 , |
299 | .Xr SSL_set_bio 3 , | 300 | .Xr SSL_set_bio 3 , |
300 | .Xr SSL_set_connect_state 3 , | 301 | .Xr SSL_set_connect_state 3 , |