# HG changeset patch # User Kim Alvefur # Date 1575159634 -3600 # Node ID b2dd1219a321fbb44fd5e60eddbecd5fe4f39007 # Parent 676e6a1b23d4cb588c597caa9fea6cb6ad91c05b mod_s2s: Improve TLS handshake error messages This should make it clearer that it's about the TLS handshake. Otherwise it's something like "unsupported protocol" or "no shared ciphers" that might not be that obvious. diff -r 676e6a1b23d4 -r b2dd1219a321 plugins/mod_s2s/mod_s2s.lua --- a/plugins/mod_s2s/mod_s2s.lua Sat Nov 30 23:33:39 2019 +0100 +++ b/plugins/mod_s2s/mod_s2s.lua Sun Dec 01 01:20:34 2019 +0100 @@ -692,6 +692,10 @@ if session then sessions[conn] = nil; (session.log or log)("debug", "s2s disconnected: %s->%s (%s)", session.from_host, session.to_host, err or "connection closed"); + if session.secure == false and err then + -- TODO util.error-ify this + err = "Error during negotiation of encrypted connection: "..err; + end s2s_destroy_session(session, err); end end