# HG changeset patch # User Matthew Wild # Date 1261432849 0 # Node ID e165414a454c2e78987d5f833515ad5822e95bf8 # Parent 57611584e27dd4f35366da7f0aad73e6f40585c0 mod_saslauth: Requiring c2s encryption means requiring c2s encryption... thanks Flo diff -r 57611584e27d -r e165414a454c plugins/mod_saslauth.lua --- a/plugins/mod_saslauth.lua Thu Dec 17 21:50:02 2009 +0000 +++ b/plugins/mod_saslauth.lua Mon Dec 21 22:00:49 2009 +0000 @@ -115,6 +115,9 @@ if not session.sasl_handler then return session.send(build_reply("failure", "invalid-mechanism")); end + if secure_auth_only and not session.secure then + return session.send(build_reply("failure", "encryption-required")); + end elseif not session.sasl_handler then return; -- FIXME ignoring out of order stanzas because ejabberd does end