Changeset

11673:3ab8496579f1

net.server_epoll: Start TLS handshake immediately on newly accepted connections Since TLS is a client-first protocol there is a chance that the ClientHello message is available already. TLS Fast Open and/or the TCP_DEFER_ACCEPT socket option would increase that chance.
author Kim Alvefur <zash@zash.se>
date Tue, 13 Jul 2021 14:20:26 +0200
parents 11672:79f8e29e88a0
children 11674:8253f6a30afc
files net/server_epoll.lua
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/net/server_epoll.lua	Tue Jul 13 14:20:24 2021 +0200
+++ b/net/server_epoll.lua	Tue Jul 13 14:20:26 2021 +0200
@@ -703,6 +703,7 @@
 		if client:inittls(self.tls_ctx) then
 			client:setreadtimeout(cfg.ssl_handshake_timeout);
 			client:setwritetimeout(cfg.ssl_handshake_timeout);
+			client:tlshandshake();
 		end
 	else
 		client:add(true, false);