diff options
author | bentley <> | 2014-10-12 09:33:04 +0000 |
---|---|---|
committer | bentley <> | 2014-10-12 09:33:04 +0000 |
commit | 82b7f378b6907ab315a6e50322d2a0a8794a0aa9 (patch) | |
tree | a5087bf8d016a6041c2b6822fbecfd8f6c5e70b1 /src/lib/libssl/doc/SSL_clear.3 | |
parent | 0a63f0cf49369e1926567ab62e04e3355cedf0cd (diff) | |
download | openbsd-82b7f378b6907ab315a6e50322d2a0a8794a0aa9.tar.gz openbsd-82b7f378b6907ab315a6e50322d2a0a8794a0aa9.tar.bz2 openbsd-82b7f378b6907ab315a6e50322d2a0a8794a0aa9.zip |
Convert libssl manpages from pod to mdoc(7).
libcrypto has not been started yet.
ok schwarze@ miod@
Diffstat (limited to 'src/lib/libssl/doc/SSL_clear.3')
-rw-r--r-- | src/lib/libssl/doc/SSL_clear.3 | 89 |
1 files changed, 89 insertions, 0 deletions
diff --git a/src/lib/libssl/doc/SSL_clear.3 b/src/lib/libssl/doc/SSL_clear.3 new file mode 100644 index 0000000000..dc596ce12a --- /dev/null +++ b/src/lib/libssl/doc/SSL_clear.3 | |||
@@ -0,0 +1,89 @@ | |||
1 | .Dd $Mdocdate: October 12 2014 $ | ||
2 | .Dt SSL_CLEAR 3 | ||
3 | .Os | ||
4 | .Sh NAME | ||
5 | .Nm SSL_clear | ||
6 | .Nd reset SSL object to allow another connection | ||
7 | .Sh SYNOPSIS | ||
8 | .In openssl/ssl.h | ||
9 | .Ft int | ||
10 | .Fn SSL_clear "SSL *ssl" | ||
11 | .Sh DESCRIPTION | ||
12 | Reset | ||
13 | .Fa ssl | ||
14 | to allow another connection. | ||
15 | All settings (method, ciphers, BIOs) are kept. | ||
16 | .Sh NOTES | ||
17 | .Fn SSL_clear | ||
18 | is used to prepare an | ||
19 | .Vt SSL | ||
20 | object for a new connection. | ||
21 | While all settings are kept, | ||
22 | a side effect is the handling of the current SSL session. | ||
23 | If a session is still | ||
24 | .Em open , | ||
25 | it is considered bad and will be removed from the session cache, | ||
26 | as required by RFC2246. | ||
27 | A session is considered open if | ||
28 | .Xr SSL_shutdown 3 | ||
29 | was not called for the connection or at least | ||
30 | .Xr SSL_set_shutdown 3 | ||
31 | was used to | ||
32 | set the | ||
33 | .Dv SSL_SENT_SHUTDOWN | ||
34 | state. | ||
35 | .Pp | ||
36 | If a session was closed cleanly, | ||
37 | the session object will be kept and all settings corresponding. | ||
38 | This explicitly means that for example the special method used during the | ||
39 | session will be kept for the next handshake. | ||
40 | So if the session was a TLSv1 session, a | ||
41 | .Vt SSL | ||
42 | client object will use a TLSv1 client method for the next handshake and a | ||
43 | .Vt SSL | ||
44 | server object will use a TLSv1 server method, even if | ||
45 | .Fn SSLv23_*_method Ns s | ||
46 | were chosen on startup. | ||
47 | This might lead to connection failures (see | ||
48 | .Xr SSL_new 3 ) | ||
49 | for a description of the method's properties. | ||
50 | .Sh WARNINGS | ||
51 | .Fn SSL_clear | ||
52 | resets the | ||
53 | .Vt SSL | ||
54 | object to allow for another connection. | ||
55 | The reset operation however keeps several settings of the last sessions | ||
56 | (some of these settings were made automatically during the last handshake). | ||
57 | It only makes sense for a new connection with the exact same peer that shares | ||
58 | these settings, | ||
59 | and may fail if that peer changes its settings between connections. | ||
60 | Use the sequence | ||
61 | .Xr SSL_get_session 3 ; | ||
62 | .Xr SSL_new 3 ; | ||
63 | .Xr SSL_set_session 3 ; | ||
64 | .Xr SSL_free 3 | ||
65 | instead to avoid such failures (or simply | ||
66 | .Xr SSL_free 3 ; | ||
67 | .Xr SSL_new 3 | ||
68 | if session reuse is not desired). | ||
69 | .Sh RETURN VALUES | ||
70 | The following return values can occur: | ||
71 | .Bl -tag -width Ds | ||
72 | .It 0 | ||
73 | The | ||
74 | .Fn SSL_clear | ||
75 | operation could not be performed. | ||
76 | Check the error stack to find out the reason. | ||
77 | .It 1 | ||
78 | The | ||
79 | .Fn SSL_clear | ||
80 | operation was successful. | ||
81 | .El | ||
82 | .Sh SEE ALSO | ||
83 | .Xr ssl 3 , | ||
84 | .Xr SSL_CTX_set_client_cert_cb 3 , | ||
85 | .Xr SSL_CTX_set_options 3 , | ||
86 | .Xr SSL_free 3 , | ||
87 | .Xr SSL_new 3 , | ||
88 | .Xr SSL_set_shutdown 3 , | ||
89 | .Xr SSL_shutdown 3 | ||