From 090bf617e12f1a84c0d1d04917f771c9684a5304 Mon Sep 17 00:00:00 2001 From: Waqas Hussain Date: Fri, 12 Feb 2010 02:43:02 +0500 Subject: [PATCH] mod_tls: Remove origin type check when TLS is requested (thanks MattJ). --- plugins/mod_tls.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/mod_tls.lua b/plugins/mod_tls.lua index 9214dd12..90985874 100644 --- a/plugins/mod_tls.lua +++ b/plugins/mod_tls.lua @@ -18,7 +18,7 @@ local global_ssl_ctx = prosody.global_ssl_ctx; module:hook("stanza/urn:ietf:params:xml:ns:xmpp-tls:starttls", function(event) local origin = event.origin; - if origin.conn.starttls and origin.type == "c2s_unauthed" or origin.type == "s2sin_unauthed" then + if origin.conn.starttls then (origin.sends2s or origin.send)(st.stanza("proceed", { xmlns = xmlns_starttls })); origin:reset_stream(); local host = origin.to_host or origin.host; -- 2.30.2