Software /
code /
prosody
Changeset
11623:cce5191a65a7
mod_s2s: Guard against LuaSec not returning TLS info here too
See previous commit to mod_c2s: a62146353528
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 21 Jun 2021 13:43:40 +0200 |
parents | 11622:a62146353528 |
children | 11624:1b7669c49459 |
files | plugins/mod_s2s.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_s2s.lua Mon Jun 21 13:36:05 2021 +0200 +++ b/plugins/mod_s2s.lua Mon Jun 21 13:43:40 2021 +0200 @@ -385,7 +385,8 @@ session.encrypted = true; local sock = session.conn:socket(); - if sock.info then + local info = sock.info and sock:info(); + if type(info) == "table" then local info = sock:info(); (session.log or log)("info", "Stream encrypted (%s with %s)", info.protocol, info.cipher); session.compressed = info.compression;