Comparison

plugins/mod_saslauth.lua @ 6038:b3ceb7627e27

Merge 0.9->0.10
author Kim Alvefur <zash@zash.se>
date Tue, 25 Mar 2014 19:16:38 +0100
parent 6014:d61026bee038
parent 6033:0d6f23049e95
child 6302:76699a0ae4c4
comparison
equal deleted inserted replaced
6037:7bbe22d8dd09 6038:b3ceb7627e27
195 local session, stanza = event.origin, event.stanza; 195 local session, stanza = event.origin, event.stanza;
196 if session.type == "s2sin_unauthed" then 196 if session.type == "s2sin_unauthed" then
197 return s2s_external_auth(session, stanza) 197 return s2s_external_auth(session, stanza)
198 end 198 end
199 199
200 if session.type ~= "c2s_unauthed" then return; end 200 if session.type ~= "c2s_unauthed" or module:get_host_type() ~= "local" then return; end
201 201
202 if session.sasl_handler and session.sasl_handler.selected then 202 if session.sasl_handler and session.sasl_handler.selected then
203 session.sasl_handler = nil; -- allow starting a new SASL negotiation before completing an old one 203 session.sasl_handler = nil; -- allow starting a new SASL negotiation before completing an old one
204 end 204 end
205 if not session.sasl_handler then 205 if not session.sasl_handler then