Software /
code /
prosody
Comparison
plugins/mod_saslauth.lua @ 2784:e165414a454c
mod_saslauth: Requiring c2s encryption means requiring c2s encryption... thanks Flo
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 21 Dec 2009 22:00:49 +0000 |
parent | 2014:913c0845ef9a |
child | 2877:1edeb8fe7d14 |
comparison
equal
deleted
inserted
replaced
2783:57611584e27d | 2784:e165414a454c |
---|---|
113 end | 113 end |
114 session.sasl_handler = new_sasl(stanza.attr.mechanism, session.host, credentials_callback); | 114 session.sasl_handler = new_sasl(stanza.attr.mechanism, session.host, credentials_callback); |
115 if not session.sasl_handler then | 115 if not session.sasl_handler then |
116 return session.send(build_reply("failure", "invalid-mechanism")); | 116 return session.send(build_reply("failure", "invalid-mechanism")); |
117 end | 117 end |
118 if secure_auth_only and not session.secure then | |
119 return session.send(build_reply("failure", "encryption-required")); | |
120 end | |
118 elseif not session.sasl_handler then | 121 elseif not session.sasl_handler then |
119 return; -- FIXME ignoring out of order stanzas because ejabberd does | 122 return; -- FIXME ignoring out of order stanzas because ejabberd does |
120 end | 123 end |
121 local text = stanza[1]; | 124 local text = stanza[1]; |
122 if text then | 125 if text then |