# HG changeset patch # User Waqas Hussain # Date 1265924582 -18000 # Node ID dff84fdebac03c241a3d09ba999ab1cde77847c9 # Parent e64c6a4aa50b096a936df0cfc9fbd8e8a27844d0 mod_tls: Remove origin type check when TLS is requested (thanks MattJ). diff -r e64c6a4aa50b -r dff84fdebac0 plugins/mod_tls.lua --- a/plugins/mod_tls.lua Fri Feb 12 02:39:50 2010 +0500 +++ b/plugins/mod_tls.lua Fri Feb 12 02:43:02 2010 +0500 @@ -18,7 +18,7 @@ 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;