Software /
code /
prosody
Diff
net/server_epoll.lua @ 11674:8253f6a30afc
net.server_epoll: Use TLS handshake timeout after initiating handshake
The :init() method sets a different timeout than the TLS related methods.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 13 Jul 2021 14:27:46 +0200 |
parent | 11673:3ab8496579f1 |
child | 11675:139d80774f11 |
line wrap: on
line diff
--- a/net/server_epoll.lua Tue Jul 13 14:20:26 2021 +0200 +++ b/net/server_epoll.lua Tue Jul 13 14:27:46 2021 +0200 @@ -613,7 +613,9 @@ self.ondrain = nil; self.onwritable = interface.tlshandshake; self.onreadable = interface.tlshandshake; - return self:init(); + self:setreadtimeout(cfg.ssl_handshake_timeout); + self:setwritetimeout(cfg.ssl_handshake_timeout); + self:add(true, true); end function interface:tlshandshake()