Debian Codegraph @

upstream/debian-unstable/man3/SSL_CTX_set_min_proto_version.3ssl

raw
1 .\" -*- mode: troff; coding: utf-8 -*-
2 .\" Automatically generated by Pod::Man 5.0102 (Pod::Simple 3.45)
3 .\"
4 .\" Standard preamble:
5 .\" ========================================================================
6 .de Sp \" Vertical space (when we can't use .PP)
7 .if t .sp .5v
8 .if n .sp
9 ..
10 .de Vb \" Begin verbatim text
11 .ft CW
12 .nf
13 .ne \\$1
14 ..
15 .de Ve \" End verbatim text
16 .ft R
17 .fi
18 ..
19 .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>.
20 .ie n \{\
21 . ds C` ""
22 . ds C' ""
23 'br\}
24 .el\{\
25 . ds C`
26 . ds C'
27 'br\}
28 .\"
29 .\" Escape single quotes in literal strings from groff's Unicode transform.
30 .ie \n(.g .ds Aq \(aq
31 .el .ds Aq '
32 .\"
33 .\" If the F register is >0, we'll generate index entries on stderr for
34 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
35 .\" entries marked with X<> in POD. Of course, you'll have to process the
36 .\" output yourself in some meaningful fashion.
37 .\"
38 .\" Avoid warning from groff about undefined register 'F'.
39 .de IX
40 ..
41 .nr rF 0
42 .if \n(.g .if rF .nr rF 1
43 .if (\n(rF:(\n(.g==0)) \{\
44 . if \nF \{\
45 . de IX
46 . tm Index:\\$1\t\\n%\t"\\$2"
47 ..
48 . if !\nF==2 \{\
49 . nr % 0
50 . nr F 2
51 . \}
52 . \}
53 .\}
54 .rr rF
55 .\" ========================================================================
56 .\"
57 .IX Title "SSL_CTX_SET_MIN_PROTO_VERSION 3SSL"
58 .TH SSL_CTX_SET_MIN_PROTO_VERSION 3SSL 2026-04-07 3.6.2 OpenSSL
59 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
60 .\" way too many mistakes in technical documents.
61 .if n .ad l
62 .nh
63 .SH NAME
64 SSL_CTX_set_min_proto_version, SSL_CTX_set_max_proto_version,
65 SSL_CTX_get_min_proto_version, SSL_CTX_get_max_proto_version,
66 SSL_set_min_proto_version, SSL_set_max_proto_version,
67 SSL_get_min_proto_version, SSL_get_max_proto_version \- Get and set minimum
68 and maximum supported protocol version
69 .SH SYNOPSIS
70 .IX Header "SYNOPSIS"
71 .Vb 1
72 \& #include <openssl/ssl.h>
73 \&
74 \& int SSL_CTX_set_min_proto_version(SSL_CTX *ctx, int version);
75 \& int SSL_CTX_set_max_proto_version(SSL_CTX *ctx, int version);
76 \& int SSL_CTX_get_min_proto_version(SSL_CTX *ctx);
77 \& int SSL_CTX_get_max_proto_version(SSL_CTX *ctx);
78 \&
79 \& int SSL_set_min_proto_version(SSL *ssl, int version);
80 \& int SSL_set_max_proto_version(SSL *ssl, int version);
81 \& int SSL_get_min_proto_version(SSL *ssl);
82 \& int SSL_get_max_proto_version(SSL *ssl);
83 .Ve
84 .SH DESCRIPTION
85 .IX Header "DESCRIPTION"
86 The functions get or set the minimum and maximum supported protocol versions
87 for the \fBctx\fR or \fBssl\fR.
88 This works in combination with the options set via
89 \&\fBSSL_CTX_set_options\fR\|(3) that also make it possible to disable
90 specific protocol versions.
91 Use these functions instead of disabling specific protocol versions.
92 .PP
93 Setting the minimum or maximum version to 0 (default), will enable protocol
94 versions down to the lowest version, or up to the highest version
95 supported by the library, respectively. The supported versions might be
96 controlled by system configuration.
97 .PP
98 Getters return 0 in case \fBctx\fR or \fBssl\fR have been configured to
99 automatically use the lowest or highest version supported by the library.
100 .PP
101 Currently supported versions are \fBSSL3_VERSION\fR, \fBTLS1_VERSION\fR,
102 \&\fBTLS1_1_VERSION\fR, \fBTLS1_2_VERSION\fR, \fBTLS1_3_VERSION\fR for TLS and
103 \&\fBDTLS1_VERSION\fR, \fBDTLS1_2_VERSION\fR for DTLS.
104 .PP
105 In the current version of OpenSSL only QUICv1 is supported in conjunction with
106 TLSv1.3. Calling these functions on a QUIC object has no effect.
107 .SH "RETURN VALUES"
108 .IX Header "RETURN VALUES"
109 These setter functions return 1 on success and 0 on failure. The getter
110 functions return the configured version or 0 for auto-configuration of
111 lowest or highest protocol, respectively.
112 .SH NOTES
113 .IX Header "NOTES"
114 All these functions are implemented using macros.
115 .SH "SEE ALSO"
116 .IX Header "SEE ALSO"
117 \&\fBssl\fR\|(7),
118 \&\fBSSL_CTX_set_options\fR\|(3), \fBSSL_CONF_cmd\fR\|(3)
119 .SH HISTORY
120 .IX Header "HISTORY"
121 The setter functions were added in OpenSSL 1.1.0. The getter functions
122 were added in OpenSSL 1.1.1.
123 .SH COPYRIGHT
124 .IX Header "COPYRIGHT"
125 Copyright 2016\-2025 The OpenSSL Project Authors. All Rights Reserved.
126 .PP
127 Licensed under the Apache License 2.0 (the "License"). You may not use
128 this file except in compliance with the License. You can obtain a copy
129 in the file LICENSE in the source distribution or at
130 <https://www.openssl.org/source/license.html>.