summaryrefslogtreecommitdiff
path: root/src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3')
-rw-r--r--src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3116
1 files changed, 116 insertions, 0 deletions
diff --git a/src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3 b/src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3
new file mode 100644
index 0000000000..91e17350f9
--- /dev/null
+++ b/src/lib/libssl/doc/SSL_CTX_set_quiet_shutdown.3
@@ -0,0 +1,116 @@
1.Dd $Mdocdate: October 12 2014 $
2.Dt SSL_CTX_SET_QUIET_SHUTDOWN 3
3.Os
4.Sh NAME
5.Nm SSL_CTX_set_quiet_shutdown ,
6.Nm SSL_CTX_get_quiet_shutdown ,
7.Nm SSL_set_quiet_shutdown ,
8.Nm SSL_get_quiet_shutdown
9.Nd manipulate shutdown behaviour
10.Sh SYNOPSIS
11.In openssl/ssl.h
12.Ft void
13.Fn SSL_CTX_set_quiet_shutdown "SSL_CTX *ctx" "int mode"
14.Ft int
15.Fn SSL_CTX_get_quiet_shutdown "const SSL_CTX *ctx"
16.Ft void
17.Fn SSL_set_quiet_shutdown "SSL *ssl" "int mode"
18.Ft int
19.Fn SSL_get_quiet_shutdown "const SSL *ssl"
20.Sh DESCRIPTION
21.Fn SSL_CTX_set_quiet_shutdown
22sets the
23.Dq quiet shutdown
24flag for
25.Fa ctx
26to be
27.Fa mode .
28.Vt SSL
29objects created from
30.Fa ctx
31inherit the
32.Fa mode
33valid at the time
34.Xr SSL_new 3
35is called.
36.Fa mode
37may be 0 or 1.
38.Pp
39.Fn SSL_CTX_get_quiet_shutdown
40returns the
41.Dq quiet shutdown
42setting of
43.Fa ctx .
44.Pp
45.Fn SSL_set_quiet_shutdown
46sets the
47.Dq quiet shutdown
48flag for
49.Fa ssl
50to be
51.Fa mode .
52The setting stays valid until
53.Fa ssl
54is removed with
55.Xr SSL_free 3
56or
57.Fn SSL_set_quiet_shutdown
58is called again.
59It is not changed when
60.Xr SSL_clear 3
61is called.
62.Fa mode
63may be 0 or 1.
64.Pp
65.Fn SSL_get_quiet_shutdown
66returns the
67.Dq quiet shutdown
68setting of
69.Fa ssl .
70.Sh NOTES
71Normally when a SSL connection is finished, the parties must send out
72.Dq close notify
73alert messages using
74.Xr SSL_shutdown 3
75for a clean shutdown.
76.Pp
77When setting the
78.Dq quiet shutdown
79flag to 1,
80.Xr SSL_shutdown 3
81will set the internal flags to
82.Dv SSL_SENT_SHUTDOWN Ns
83.Pf |
84.Dv SSL_RECEIVED_SHUTDOWN .
85.Po
86.Xr SSL_shutdown 3
87then behaves like
88.Xr SSL_set_shutdown 3
89called with
90.Dv SSL_SENT_SHUTDOWN Ns
91.Pf |
92.Dv SSL_RECEIVED_SHUTDOWN .
93.Pc
94The session is thus considered to be shut down, but no
95.Dq close notify
96alert is sent to the peer.
97This behaviour violates the TLS standard.
98.Pp
99The default is normal shutdown behaviour as described by the TLS standard.
100.Sh RETURN VALUES
101.Fn SSL_CTX_set_quiet_shutdown
102and
103.Fn SSL_set_quiet_shutdown
104do not return diagnostic information.
105.Pp
106.Fn SSL_CTX_get_quiet_shutdown
107and
108.Fn SSL_get_quiet_shutdown
109return the current setting.
110.Sh SEE ALSO
111.Xr ssl 3 ,
112.Xr SSL_clear 3 ,
113.Xr SSL_free 3 ,
114.Xr SSL_new 3 ,
115.Xr SSL_set_shutdown 3 ,
116.Xr SSL_shutdown 3