From 217ecf012aff5f1b451a06ac47f8f7631949848b Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 25 Feb 2017 01:16:31 +0100 Subject: mod_tls: Suppress debug message if already using encryption --- plugins/mod_tls.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'plugins/mod_tls.lua') diff --git a/plugins/mod_tls.lua b/plugins/mod_tls.lua index 3903a760..fbeb344b 100644 --- a/plugins/mod_tls.lua +++ b/plugins/mod_tls.lua @@ -63,7 +63,9 @@ end local function can_do_tls(session) if not session.conn.starttls then - session.log("debug", "Underlying connection does not support STARTTLS"); + if not session.secure then + session.log("debug", "Underlying connection does not support STARTTLS"); + end return false; elseif session.ssl_ctx ~= nil then return session.ssl_ctx; -- cgit v1.2.3