You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
133 lines
4.1 KiB
133 lines
4.1 KiB
3 years ago
|
diff --git a/features.c b/features.c
|
||
|
index d024366..3a60b88 100644
|
||
|
--- a/features.c
|
||
|
+++ b/features.c
|
||
|
@@ -22,7 +22,7 @@ handle_feat(struct vsf_session* p_sess)
|
||
|
{
|
||
|
vsf_cmdio_write_raw(p_sess, " AUTH SSL\r\n");
|
||
|
}
|
||
|
- if (tunable_tlsv1 || tunable_tlsv1_1 || tunable_tlsv1_2)
|
||
|
+ if (tunable_tlsv1 || tunable_tlsv1_1 || tunable_tlsv1_2 || tunable_tlsv1_3)
|
||
|
{
|
||
|
vsf_cmdio_write_raw(p_sess, " AUTH TLS\r\n");
|
||
|
}
|
||
|
diff --git a/parseconf.c b/parseconf.c
|
||
|
index 3729818..2c5ffe6 100644
|
||
|
--- a/parseconf.c
|
||
|
+++ b/parseconf.c
|
||
|
@@ -87,6 +87,7 @@ parseconf_bool_array[] =
|
||
|
{ "ssl_tlsv1", &tunable_tlsv1 },
|
||
|
{ "ssl_tlsv1_1", &tunable_tlsv1_1 },
|
||
|
{ "ssl_tlsv1_2", &tunable_tlsv1_2 },
|
||
|
+ { "ssl_tlsv1_3", &tunable_tlsv1_3 },
|
||
|
{ "tilde_user_enable", &tunable_tilde_user_enable },
|
||
|
{ "force_anon_logins_ssl", &tunable_force_anon_logins_ssl },
|
||
|
{ "force_anon_data_ssl", &tunable_force_anon_data_ssl },
|
||
|
diff --git a/ssl.c b/ssl.c
|
||
|
index 09ec96a..5d9c595 100644
|
||
|
--- a/ssl.c
|
||
|
+++ b/ssl.c
|
||
|
@@ -178,6 +178,10 @@ ssl_init(struct vsf_session* p_sess)
|
||
|
{
|
||
|
options |= SSL_OP_NO_TLSv1_2;
|
||
|
}
|
||
|
+ if (!tunable_tlsv1_3)
|
||
|
+ {
|
||
|
+ options |= SSL_OP_NO_TLSv1_3;
|
||
|
+ }
|
||
|
SSL_CTX_set_options(p_ctx, options);
|
||
|
if (tunable_rsa_cert_file)
|
||
|
{
|
||
|
diff --git a/tunables.c b/tunables.c
|
||
|
index c96c1ac..e6fbb9d 100644
|
||
|
--- a/tunables.c
|
||
|
+++ b/tunables.c
|
||
|
@@ -68,6 +68,7 @@ int tunable_sslv3;
|
||
|
int tunable_tlsv1;
|
||
|
int tunable_tlsv1_1;
|
||
|
int tunable_tlsv1_2;
|
||
|
+int tunable_tlsv1_3;
|
||
|
int tunable_tilde_user_enable;
|
||
|
int tunable_force_anon_logins_ssl;
|
||
|
int tunable_force_anon_data_ssl;
|
||
|
@@ -217,8 +218,9 @@ tunables_load_defaults()
|
||
|
tunable_sslv3 = 0;
|
||
|
tunable_tlsv1 = 0;
|
||
|
tunable_tlsv1_1 = 0;
|
||
|
- /* Only TLSv1.2 is enabled by default */
|
||
|
+ /* Only TLSv1.2 and TLSv1.3 are enabled by default */
|
||
|
tunable_tlsv1_2 = 1;
|
||
|
+ tunable_tlsv1_3 = 1;
|
||
|
tunable_tilde_user_enable = 0;
|
||
|
tunable_force_anon_logins_ssl = 0;
|
||
|
tunable_force_anon_data_ssl = 0;
|
||
|
diff --git a/tunables.h b/tunables.h
|
||
|
index 8d50150..6e1d301 100644
|
||
|
--- a/tunables.h
|
||
|
+++ b/tunables.h
|
||
|
@@ -69,6 +69,7 @@ extern int tunable_sslv3; /* Allow SSLv3 */
|
||
|
extern int tunable_tlsv1; /* Allow TLSv1 */
|
||
|
extern int tunable_tlsv1_1; /* Allow TLSv1.1 */
|
||
|
extern int tunable_tlsv1_2; /* Allow TLSv1.2 */
|
||
|
+extern int tunable_tlsv1_3; /* Allow TLSv1.3 */
|
||
|
extern int tunable_tilde_user_enable; /* Support e.g. ~chris */
|
||
|
extern int tunable_force_anon_logins_ssl; /* Require anon logins use SSL */
|
||
|
extern int tunable_force_anon_data_ssl; /* Require anon data uses SSL */
|
||
|
diff --git a/vsftpd.conf.5 b/vsftpd.conf.5
|
||
|
index 815773f..c37a536 100644
|
||
|
--- a/vsftpd.conf.5
|
||
|
+++ b/vsftpd.conf.5
|
||
|
@@ -555,7 +555,7 @@ Default: YES
|
||
|
Only applies if
|
||
|
.BR ssl_enable
|
||
|
is activated. If enabled, this option will permit SSL v2 protocol connections.
|
||
|
-TLS v1.2 connections are preferred.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
|
||
|
Default: NO
|
||
|
.TP
|
||
|
@@ -563,7 +563,7 @@ Default: NO
|
||
|
Only applies if
|
||
|
.BR ssl_enable
|
||
|
is activated. If enabled, this option will permit SSL v3 protocol connections.
|
||
|
-TLS v1.2 connections are preferred.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
|
||
|
Default: NO
|
||
|
.TP
|
||
|
@@ -571,7 +571,7 @@ Default: NO
|
||
|
Only applies if
|
||
|
.BR ssl_enable
|
||
|
is activated. If enabled, this option will permit TLS v1 protocol connections.
|
||
|
-TLS v1.2 connections are preferred.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
|
||
|
Default: NO
|
||
|
.TP
|
||
|
@@ -579,7 +579,7 @@ Default: NO
|
||
|
Only applies if
|
||
|
.BR ssl_enable
|
||
|
is activated. If enabled, this option will permit TLS v1.1 protocol connections.
|
||
|
-TLS v1.2 connections are preferred.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
|
||
|
Default: NO
|
||
|
.TP
|
||
|
@@ -587,7 +587,15 @@ Default: NO
|
||
|
Only applies if
|
||
|
.BR ssl_enable
|
||
|
is activated. If enabled, this option will permit TLS v1.2 protocol connections.
|
||
|
-TLS v1.2 connections are preferred.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
+
|
||
|
+Default: YES
|
||
|
+.TP
|
||
|
+.B ssl_tlsv1_3
|
||
|
+Only applies if
|
||
|
+.BR ssl_enable
|
||
|
+is activated. If enabled, this option will permit TLS v1.3 protocol connections.
|
||
|
+TLS v1.2 and TLS v1.3 connections are preferred.
|
||
|
|
||
|
Default: YES
|
||
|
.TP
|