Software /
code /
prosody
Changeset
11519:df4bd3af4099
mod_tls: Bail out if session got destroyed while sending <proceed/>
Can happen in case opportunistic_writes is enabled and the session got
destroyed while writing that tag.
Thanks Ge0rG
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 15 Apr 2021 15:57:24 +0200 |
parents | 11518:3f1a865e9419 |
children | 11520:0a464a6e88c4 |
files | plugins/mod_tls.lua |
diffstat | 1 files changed, 1 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_tls.lua Thu Apr 15 15:12:35 2021 +0200 +++ b/plugins/mod_tls.lua Thu Apr 15 15:57:24 2021 +0200 @@ -121,6 +121,7 @@ local origin = event.origin; if can_do_tls(origin) then (origin.sends2s or origin.send)(starttls_proceed); + if origin.destroyed then return end origin:reset_stream(); origin.conn:starttls(origin.ssl_ctx); origin.log("debug", "TLS negotiation started for %s...", origin.type);