Software /
code /
prosody
Comparison
plugins/mod_proxy65.lua @ 3005:c49be80767ee
mod_proxy65: Return service-unavailable error when receiving an iq we didn't understand
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Wed, 05 May 2010 15:32:16 +0100 |
parent | 3004:c20b9fe1624b |
child | 3006:a3580f556c27 |
comparison
equal
deleted
inserted
replaced
3004:c20b9fe1624b | 3005:c49be80767ee |
---|---|
234 origin.send(get_disco_items(stanza)); | 234 origin.send(get_disco_items(stanza)); |
235 return true; | 235 return true; |
236 elseif xmlns == "http://jabber.org/protocol/bytestreams" then | 236 elseif xmlns == "http://jabber.org/protocol/bytestreams" then |
237 origin.send(get_stream_host(origin, stanza)); | 237 origin.send(get_stream_host(origin, stanza)); |
238 return true; | 238 return true; |
239 else | |
240 origin.send(st.error_reply(stanza, "cancel", "service-unavailable")); | |
241 return true; | |
239 end | 242 end |
240 elseif stanza.name == "iq" and type == "set" then | 243 elseif stanza.name == "iq" and type == "set" then |
241 local reply, from, to, sid = set_activation(stanza); | 244 local reply, from, to, sid = set_activation(stanza); |
242 if reply ~= nil and from ~= nil and to ~= nil and sid ~= nil then | 245 if reply ~= nil and from ~= nil and to ~= nil and sid ~= nil then |
243 local sha = sha1(sid .. from .. to, true); | 246 local sha = sha1(sid .. from .. to, true); |