]> CyberLeo.Net >> Repos - FreeBSD/releng/8.1.git/blob - secure/lib/libssl/man/SSL_CTX_set_options.3
Copy stable/8 to releng/8.1 in preparation for 8.1-RC1.
[FreeBSD/releng/8.1.git] / secure / lib / libssl / man / SSL_CTX_set_options.3
1 .\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.37
2 .\"
3 .\" Standard preamble:
4 .\" ========================================================================
5 .de Sh \" Subsection heading
6 .br
7 .if t .Sp
8 .ne 5
9 .PP
10 \fB\\$1\fR
11 .PP
12 ..
13 .de Sp \" Vertical space (when we can't use .PP)
14 .if t .sp .5v
15 .if n .sp
16 ..
17 .de Vb \" Begin verbatim text
18 .ft CW
19 .nf
20 .ne \\$1
21 ..
22 .de Ve \" End verbatim text
23 .ft R
24 .fi
25 ..
26 .\" Set up some character translations and predefined strings.  \*(-- will
27 .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
28 .\" double quote, and \*(R" will give a right double quote.  | will give a
29 .\" real vertical bar.  \*(C+ will give a nicer C++.  Capital omega is used to
30 .\" do unbreakable dashes and therefore won't be available.  \*(C` and \*(C'
31 .\" expand to `' in nroff, nothing in troff, for use with C<>.
32 .tr \(*W-|\(bv\*(Tr
33 .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
34 .ie n \{\
35 .    ds -- \(*W-
36 .    ds PI pi
37 .    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
38 .    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch
39 .    ds L" ""
40 .    ds R" ""
41 .    ds C` ""
42 .    ds C' ""
43 'br\}
44 .el\{\
45 .    ds -- \|\(em\|
46 .    ds PI \(*p
47 .    ds L" ``
48 .    ds R" ''
49 'br\}
50 .\"
51 .\" If the F register is turned on, we'll generate index entries on stderr for
52 .\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index
53 .\" entries marked with X<> in POD.  Of course, you'll have to process the
54 .\" output yourself in some meaningful fashion.
55 .if \nF \{\
56 .    de IX
57 .    tm Index:\\$1\t\\n%\t"\\$2"
58 ..
59 .    nr % 0
60 .    rr F
61 .\}
62 .\"
63 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
64 .\" way too many mistakes in technical documents.
65 .hy 0
66 .if n .na
67 .\"
68 .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
69 .\" Fear.  Run.  Save yourself.  No user-serviceable parts.
70 .    \" fudge factors for nroff and troff
71 .if n \{\
72 .    ds #H 0
73 .    ds #V .8m
74 .    ds #F .3m
75 .    ds #[ \f1
76 .    ds #] \fP
77 .\}
78 .if t \{\
79 .    ds #H ((1u-(\\\\n(.fu%2u))*.13m)
80 .    ds #V .6m
81 .    ds #F 0
82 .    ds #[ \&
83 .    ds #] \&
84 .\}
85 .    \" simple accents for nroff and troff
86 .if n \{\
87 .    ds ' \&
88 .    ds ` \&
89 .    ds ^ \&
90 .    ds , \&
91 .    ds ~ ~
92 .    ds /
93 .\}
94 .if t \{\
95 .    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
96 .    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
97 .    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
98 .    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
99 .    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
100 .    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
101 .\}
102 .    \" troff and (daisy-wheel) nroff accents
103 .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
104 .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
105 .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
106 .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
107 .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
108 .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
109 .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
110 .ds ae a\h'-(\w'a'u*4/10)'e
111 .ds Ae A\h'-(\w'A'u*4/10)'E
112 .    \" corrections for vroff
113 .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
114 .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
115 .    \" for low resolution devices (crt and lpr)
116 .if \n(.H>23 .if \n(.V>19 \
117 \{\
118 .    ds : e
119 .    ds 8 ss
120 .    ds o a
121 .    ds d- d\h'-1'\(ga
122 .    ds D- D\h'-1'\(hy
123 .    ds th \o'bp'
124 .    ds Th \o'LP'
125 .    ds ae ae
126 .    ds Ae AE
127 .\}
128 .rm #[ #] #H #V #F C
129 .\" ========================================================================
130 .\"
131 .IX Title "SSL_CTX_set_options 3"
132 .TH SSL_CTX_set_options 3 "2010-03-24" "0.9.8n" "OpenSSL"
133 .SH "NAME"
134 SSL_CTX_set_options, SSL_set_options, SSL_CTX_clear_options, SSL_clear_options, SSL_CTX_get_options, SSL_get_options, SSL_get_secure_renegotiation_support \- manipulate SSL options
135 .SH "SYNOPSIS"
136 .IX Header "SYNOPSIS"
137 .Vb 1
138 \& #include <openssl/ssl.h>
139 .Ve
140 .PP
141 .Vb 2
142 \& long SSL_CTX_set_options(SSL_CTX *ctx, long options);
143 \& long SSL_set_options(SSL *ssl, long options);
144 .Ve
145 .PP
146 .Vb 2
147 \& long SSL_CTX_clear_options(SSL_CTX *ctx, long options);
148 \& long SSL_clear_options(SSL *ssl, long options);
149 .Ve
150 .PP
151 .Vb 2
152 \& long SSL_CTX_get_options(SSL_CTX *ctx);
153 \& long SSL_get_options(SSL *ssl);
154 .Ve
155 .PP
156 .Vb 1
157 \& long SSL_get_secure_renegotiation_support(SSL *ssl);
158 .Ve
159 .SH "DESCRIPTION"
160 .IX Header "DESCRIPTION"
161 Note: all these functions are implemented using macros.
162 .PP
163 \&\fISSL_CTX_set_options()\fR adds the options set via bitmask in \fBoptions\fR to \fBctx\fR.
164 Options already set before are not cleared!
165 .PP
166 \&\fISSL_set_options()\fR adds the options set via bitmask in \fBoptions\fR to \fBssl\fR.
167 Options already set before are not cleared!
168 .PP
169 \&\fISSL_CTX_clear_options()\fR clears the options set via bitmask in \fBoptions\fR
170 to \fBctx\fR.
171 .PP
172 \&\fISSL_clear_options()\fR clears the options set via bitmask in \fBoptions\fR to \fBssl\fR.
173 .PP
174 \&\fISSL_CTX_get_options()\fR returns the options set for \fBctx\fR.
175 .PP
176 \&\fISSL_get_options()\fR returns the options set for \fBssl\fR.
177 .PP
178 \&\fISSL_get_secure_renegotiation_support()\fR indicates whether the peer supports
179 secure renegotiation.
180 .SH "NOTES"
181 .IX Header "NOTES"
182 The behaviour of the \s-1SSL\s0 library can be changed by setting several options.
183 The options are coded as bitmasks and can be combined by a logical \fBor\fR
184 operation (|).
185 .PP
186 \&\fISSL_CTX_set_options()\fR and \fISSL_set_options()\fR affect the (external)
187 protocol behaviour of the \s-1SSL\s0 library. The (internal) behaviour of
188 the \s-1API\s0 can be changed by using the similar
189 \&\fISSL_CTX_set_mode\fR\|(3) and \fISSL_set_mode()\fR functions.
190 .PP
191 During a handshake, the option settings of the \s-1SSL\s0 object are used. When
192 a new \s-1SSL\s0 object is created from a context using \fISSL_new()\fR, the current
193 option setting is copied. Changes to \fBctx\fR do not affect already created
194 \&\s-1SSL\s0 objects. \fISSL_clear()\fR does not affect the settings.
195 .PP
196 The following \fBbug workaround\fR options are available:
197 .IP "\s-1SSL_OP_MICROSOFT_SESS_ID_BUG\s0" 4
198 .IX Item "SSL_OP_MICROSOFT_SESS_ID_BUG"
199 www.microsoft.com \- when talking SSLv2, if session-id reuse is
200 performed, the session-id passed back in the server-finished message
201 is different from the one decided upon.
202 .IP "\s-1SSL_OP_NETSCAPE_CHALLENGE_BUG\s0" 4
203 .IX Item "SSL_OP_NETSCAPE_CHALLENGE_BUG"
204 Netscape\-Commerce/1.12, when talking SSLv2, accepts a 32 byte
205 challenge but then appears to only use 16 bytes when generating the
206 encryption keys.  Using 16 bytes is ok but it should be ok to use 32.
207 According to the SSLv3 spec, one should use 32 bytes for the challenge
208 when operating in SSLv2/v3 compatibility mode, but as mentioned above,
209 this breaks this server so 16 bytes is the way to go.
210 .IP "\s-1SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG\s0" 4
211 .IX Item "SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG"
212 ssl3.netscape.com:443, first a connection is established with \s-1RC4\-MD5\s0.
213 If it is then resumed, we end up using \s-1DES\-CBC3\-SHA\s0.  It should be
214 \&\s-1RC4\-MD5\s0 according to 7.6.1.3, 'cipher_suite'.
215 .Sp
216 Netscape\-Enterprise/2.01 (https://merchant.netscape.com) has this bug.
217 It only really shows up when connecting via SSLv2/v3 then reconnecting
218 via SSLv3. The cipher list changes....
219 .Sp
220 \&\s-1NEW\s0 \s-1INFORMATION\s0.  Try connecting with a cipher list of just
221 \&\s-1DES\-CBC\-SHA:RC4\-MD5\s0.  For some weird reason, each new connection uses
222 \&\s-1RC4\-MD5\s0, but a re-connect tries to use \s-1DES\-CBC\-SHA\s0.  So netscape, when
223 doing a re\-connect, always takes the first cipher in the cipher list.
224 .IP "\s-1SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG\s0" 4
225 .IX Item "SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG"
226 \&...
227 .IP "\s-1SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER\s0" 4
228 .IX Item "SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER"
229 \&...
230 .IP "\s-1SSL_OP_MSIE_SSLV2_RSA_PADDING\s0" 4
231 .IX Item "SSL_OP_MSIE_SSLV2_RSA_PADDING"
232 As of OpenSSL 0.9.7h and 0.9.8a, this option has no effect.
233 .IP "\s-1SSL_OP_SSLEAY_080_CLIENT_DH_BUG\s0" 4
234 .IX Item "SSL_OP_SSLEAY_080_CLIENT_DH_BUG"
235 \&...
236 .IP "\s-1SSL_OP_TLS_D5_BUG\s0" 4
237 .IX Item "SSL_OP_TLS_D5_BUG"
238 \&...
239 .IP "\s-1SSL_OP_TLS_BLOCK_PADDING_BUG\s0" 4
240 .IX Item "SSL_OP_TLS_BLOCK_PADDING_BUG"
241 \&...
242 .IP "\s-1SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS\s0" 4
243 .IX Item "SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS"
244 Disables a countermeasure against a \s-1SSL\s0 3.0/TLS 1.0 protocol
245 vulnerability affecting \s-1CBC\s0 ciphers, which cannot be handled by some
246 broken \s-1SSL\s0 implementations.  This option has no effect for connections
247 using other ciphers.
248 .IP "\s-1SSL_OP_ALL\s0" 4
249 .IX Item "SSL_OP_ALL"
250 All of the above bug workarounds.
251 .PP
252 It is usually safe to use \fB\s-1SSL_OP_ALL\s0\fR to enable the bug workaround
253 options if compatibility with somewhat broken implementations is
254 desired.
255 .PP
256 The following \fBmodifying\fR options are available:
257 .IP "\s-1SSL_OP_TLS_ROLLBACK_BUG\s0" 4
258 .IX Item "SSL_OP_TLS_ROLLBACK_BUG"
259 Disable version rollback attack detection.
260 .Sp
261 During the client key exchange, the client must send the same information
262 about acceptable \s-1SSL/TLS\s0 protocol levels as during the first hello. Some
263 clients violate this rule by adapting to the server's answer. (Example:
264 the client sends a SSLv2 hello and accepts up to SSLv3.1=TLSv1, the server
265 only understands up to SSLv3. In this case the client must still use the
266 same SSLv3.1=TLSv1 announcement. Some clients step down to SSLv3 with respect
267 to the server's answer and violate the version rollback protection.)
268 .IP "\s-1SSL_OP_SINGLE_DH_USE\s0" 4
269 .IX Item "SSL_OP_SINGLE_DH_USE"
270 Always create a new key when using temporary/ephemeral \s-1DH\s0 parameters
271 (see \fISSL_CTX_set_tmp_dh_callback\fR\|(3)).
272 This option must be used to prevent small subgroup attacks, when
273 the \s-1DH\s0 parameters were not generated using \*(L"strong\*(R" primes
274 (e.g. when using DSA\-parameters, see \fIdhparam\fR\|(1)).
275 If \*(L"strong\*(R" primes were used, it is not strictly necessary to generate
276 a new \s-1DH\s0 key during each handshake but it is also recommended.
277 \&\fB\s-1SSL_OP_SINGLE_DH_USE\s0\fR should therefore be enabled whenever
278 temporary/ephemeral \s-1DH\s0 parameters are used.
279 .IP "\s-1SSL_OP_EPHEMERAL_RSA\s0" 4
280 .IX Item "SSL_OP_EPHEMERAL_RSA"
281 Always use ephemeral (temporary) \s-1RSA\s0 key when doing \s-1RSA\s0 operations
282 (see \fISSL_CTX_set_tmp_rsa_callback\fR\|(3)).
283 According to the specifications this is only done, when a \s-1RSA\s0 key
284 can only be used for signature operations (namely under export ciphers
285 with restricted \s-1RSA\s0 keylength). By setting this option, ephemeral
286 \&\s-1RSA\s0 keys are always used. This option breaks compatibility with the
287 \&\s-1SSL/TLS\s0 specifications and may lead to interoperability problems with
288 clients and should therefore never be used. Ciphers with \s-1EDH\s0 (ephemeral
289 Diffie\-Hellman) key exchange should be used instead.
290 .IP "\s-1SSL_OP_CIPHER_SERVER_PREFERENCE\s0" 4
291 .IX Item "SSL_OP_CIPHER_SERVER_PREFERENCE"
292 When choosing a cipher, use the server's preferences instead of the client
293 preferences. When not set, the \s-1SSL\s0 server will always follow the clients
294 preferences. When set, the SSLv3/TLSv1 server will choose following its
295 own preferences. Because of the different protocol, for SSLv2 the server
296 will send its list of preferences to the client and the client chooses.
297 .IP "\s-1SSL_OP_PKCS1_CHECK_1\s0" 4
298 .IX Item "SSL_OP_PKCS1_CHECK_1"
299 \&...
300 .IP "\s-1SSL_OP_PKCS1_CHECK_2\s0" 4
301 .IX Item "SSL_OP_PKCS1_CHECK_2"
302 \&...
303 .IP "\s-1SSL_OP_NETSCAPE_CA_DN_BUG\s0" 4
304 .IX Item "SSL_OP_NETSCAPE_CA_DN_BUG"
305 If we accept a netscape connection, demand a client cert, have a
306 non-self-signed \s-1CA\s0 which does not have its \s-1CA\s0 in netscape, and the
307 browser has a cert, it will crash/hang.  Works for 3.x and 4.xbeta 
308 .IP "\s-1SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG\s0" 4
309 .IX Item "SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG"
310 \&...
311 .IP "SSL_OP_NO_SSLv2" 4
312 .IX Item "SSL_OP_NO_SSLv2"
313 Do not use the SSLv2 protocol.
314 .IP "SSL_OP_NO_SSLv3" 4
315 .IX Item "SSL_OP_NO_SSLv3"
316 Do not use the SSLv3 protocol.
317 .IP "SSL_OP_NO_TLSv1" 4
318 .IX Item "SSL_OP_NO_TLSv1"
319 Do not use the TLSv1 protocol.
320 .IP "\s-1SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION\s0" 4
321 .IX Item "SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION"
322 When performing renegotiation as a server, always start a new session
323 (i.e., session resumption requests are only accepted in the initial
324 handshake). This option is not needed for clients.
325 .IP "\s-1SSL_OP_NO_TICKET\s0" 4
326 .IX Item "SSL_OP_NO_TICKET"
327 Normally clients and servers will, where possible, transparently make use
328 of RFC4507bis tickets for stateless session resumption if extension support
329 is explicitly set when OpenSSL is compiled.
330 .Sp
331 If this option is set this functionality is disabled and tickets will
332 not be used by clients or servers.
333 .IP "\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0" 4
334 .IX Item "SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION"
335 Allow legacy insecure renegotiation between OpenSSL and unpatched clients or
336 servers. See the \fB\s-1SECURE\s0 \s-1RENEGOTIATION\s0\fR section for more details.
337 .IP "\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0" 4
338 .IX Item "SSL_OP_LEGACY_SERVER_CONNECT"
339 Allow legacy insecure renegotiation between OpenSSL and unpatched servers
340 \&\fBonly\fR: this option is currently set by default. See the
341 \&\fB\s-1SECURE\s0 \s-1RENEGOTIATION\s0\fR section for more details.
342 .SH "SECURE RENEGOTIATION"
343 .IX Header "SECURE RENEGOTIATION"
344 OpenSSL 0.9.8m and later always attempts to use secure renegotiation as
345 described in \s-1RFC5746\s0. This counters the prefix attack described in
346 \&\s-1CVE\-2009\-3555\s0 and elsewhere.
347 .PP
348 The deprecated and highly broken SSLv2 protocol does not support
349 renegotiation at all: its use is \fBstrongly\fR discouraged.
350 .PP
351 This attack has far reaching consequences which application writers should be
352 aware of. In the description below an implementation supporting secure
353 renegotiation is referred to as \fIpatched\fR. A server not supporting secure
354 renegotiation is referred to as \fIunpatched\fR.
355 .PP
356 The following sections describe the operations permitted by OpenSSL's secure
357 renegotiation implementation.
358 .Sh "Patched client and server"
359 .IX Subsection "Patched client and server"
360 Connections and renegotiation are always permitted by OpenSSL implementations.
361 .Sh "Unpatched client and patched OpenSSL server"
362 .IX Subsection "Unpatched client and patched OpenSSL server"
363 The initial connection suceeds but client renegotiation is denied by the
364 server with a \fBno_renegotiation\fR warning alert if \s-1TLS\s0 v1.0 is used or a fatal
365 \&\fBhandshake_failure\fR alert in \s-1SSL\s0 v3.0.
366 .PP
367 If the patched OpenSSL server attempts to renegotiate a fatal
368 \&\fBhandshake_failure\fR alert is sent. This is because the server code may be
369 unaware of the unpatched nature of the client.
370 .PP
371 If the option \fB\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0\fR is set then
372 renegotiation \fBalways\fR succeeds.
373 .PP
374 \&\fB\s-1NB:\s0\fR a bug in OpenSSL clients earlier than 0.9.8m (all of which are
375 unpatched) will result in the connection hanging if it receives a
376 \&\fBno_renegotiation\fR alert. OpenSSL versions 0.9.8m and later will regard
377 a \fBno_renegotiation\fR alert as fatal and respond with a fatal
378 \&\fBhandshake_failure\fR alert. This is because the OpenSSL \s-1API\s0 currently has
379 no provision to indicate to an application that a renegotiation attempt
380 was refused.
381 .Sh "Patched OpenSSL client and unpatched server."
382 .IX Subsection "Patched OpenSSL client and unpatched server."
383 If the option \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR or
384 \&\fB\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0\fR is set then initial connections
385 and renegotiation between patched OpenSSL clients and unpatched servers
386 succeeds. If neither option is set then initial connections to unpatched
387 servers will fail.
388 .PP
389 The option \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR is currently set by default even
390 though it has security implications: otherwise it would be impossible to
391 connect to unpatched servers (i.e. all of them initially) and this is clearly
392 not acceptable. Renegotiation is permitted because this does not add any
393 additional security issues: during an attack clients do not see any
394 renegotiations anyway.
395 .PP
396 As more servers become patched the option \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR will
397 \&\fBnot\fR be set by default in a future version of OpenSSL.
398 .PP
399 OpenSSL client applications wishing to ensure they can connect to unpatched
400 servers should always \fBset\fR \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR
401 .PP
402 OpenSSL client applications that want to ensure they can \fBnot\fR connect to
403 unpatched servers (and thus avoid any security issues) should always \fBclear\fR
404 \&\fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR using \fISSL_CTX_clear_options()\fR or
405 \&\fISSL_clear_options()\fR.
406 .PP
407 The difference between the \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR and
408 \&\fB\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0\fR options is that
409 \&\fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR enables initial connections and secure
410 renegotiation between OpenSSL clients and unpatched servers \fBonly\fR, while
411 \&\fB\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0\fR allows initial connections
412 and renegotiation between OpenSSL and unpatched clients or servers.
413 .SH "RETURN VALUES"
414 .IX Header "RETURN VALUES"
415 \&\fISSL_CTX_set_options()\fR and \fISSL_set_options()\fR return the new options bitmask
416 after adding \fBoptions\fR.
417 .PP
418 \&\fISSL_CTX_clear_options()\fR and \fISSL_clear_options()\fR return the new options bitmask
419 after clearing \fBoptions\fR.
420 .PP
421 \&\fISSL_CTX_get_options()\fR and \fISSL_get_options()\fR return the current bitmask.
422 .PP
423 \&\fISSL_get_secure_renegotiation_support()\fR returns 1 is the peer supports
424 secure renegotiation and 0 if it does not.
425 .SH "SEE ALSO"
426 .IX Header "SEE ALSO"
427 \&\fIssl\fR\|(3), \fISSL_new\fR\|(3), \fISSL_clear\fR\|(3),
428 \&\fISSL_CTX_set_tmp_dh_callback\fR\|(3),
429 \&\fISSL_CTX_set_tmp_rsa_callback\fR\|(3),
430 \&\fIdhparam\fR\|(1)
431 .SH "HISTORY"
432 .IX Header "HISTORY"
433 \&\fB\s-1SSL_OP_CIPHER_SERVER_PREFERENCE\s0\fR and
434 \&\fB\s-1SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION\s0\fR have been added in
435 OpenSSL 0.9.7.
436 .PP
437 \&\fB\s-1SSL_OP_TLS_ROLLBACK_BUG\s0\fR has been added in OpenSSL 0.9.6 and was automatically
438 enabled with \fB\s-1SSL_OP_ALL\s0\fR. As of 0.9.7, it is no longer included in \fB\s-1SSL_OP_ALL\s0\fR
439 and must be explicitly set.
440 .PP
441 \&\fB\s-1SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS\s0\fR has been added in OpenSSL 0.9.6e.
442 Versions up to OpenSSL 0.9.6c do not include the countermeasure that
443 can be disabled with this option (in OpenSSL 0.9.6d, it was always
444 enabled).
445 .PP
446 \&\fISSL_CTX_clear_options()\fR and \fISSL_clear_options()\fR were first added in OpenSSL
447 0.9.8m.
448 .PP
449 \&\fB\s-1SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION\s0\fR, \fB\s-1SSL_OP_LEGACY_SERVER_CONNECT\s0\fR
450 and the function \fISSL_get_secure_renegotiation_support()\fR were first added in
451 OpenSSL 0.9.8m.