Comparison

plugins/mod_component.lua @ 3503:85e511e01d3c

net.xmppcomponent_listener, mod_component: Removed useless undocumented option 'component_address'.
author Waqas Hussain <waqas20@gmail.com>
date Tue, 21 Sep 2010 17:37:11 +0500
parent 3319:95fc08869273
child 3531:f41e1cfe92f4
comparison
equal deleted inserted replaced
3502:28887137bb1b 3503:85e511e01d3c
29 (session.log or log)("warn", "Component handshake invalid"); 29 (session.log or log)("warn", "Component handshake invalid");
30 session:close("not-authorized"); 30 session:close("not-authorized");
31 return; 31 return;
32 end 32 end
33 33
34 local secret = config.get(session.user, "core", "component_secret"); 34 local secret = config.get(session.host, "core", "component_secret");
35 if not secret then 35 if not secret then
36 (session.log or log)("warn", "Component attempted to identify as %s, but component_secret is not set", session.user); 36 (session.log or log)("warn", "Component attempted to identify as %s, but component_secret is not set", session.host);
37 session:close("not-authorized"); 37 session:close("not-authorized");
38 return; 38 return;
39 end 39 end
40 40
41 local supplied_token = t_concat(stanza); 41 local supplied_token = t_concat(stanza);