Software /
code /
prosody
Diff
plugins/mod_saslauth.lua @ 3524:d206b4e0a9f3
mod_saslauth: Improved logging a bit.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Sat, 16 Oct 2010 05:16:45 +0500 |
parent | 3523:32a0c3816d73 |
child | 3535:b953b0c0f203 |
line wrap: on
line diff
--- a/plugins/mod_saslauth.lua Sat Oct 16 05:03:00 2010 +0500 +++ b/plugins/mod_saslauth.lua Sat Oct 16 05:16:45 2010 +0500 @@ -142,7 +142,6 @@ end); module:hook("iq/self/urn:ietf:params:xml:ns:xmpp-bind:bind", function(event) - log("debug", "Client requesting a resource bind"); local origin, stanza = event.origin, event.stanza; local resource; if stanza.attr.type == "set" then @@ -155,14 +154,15 @@ origin.send(st.reply(stanza) :tag("bind", { xmlns = xmlns_bind }) :tag("jid"):text(origin.full_jid)); + origin.log("debug", "Resource bound: %s", origin.full_jid); else origin.send(st.error_reply(stanza, err_type, err, err_msg)); + origin.log("debug", "Resource bind failed: %s", err_msg or err); end return true; end); module:hook("iq/self/urn:ietf:params:xml:ns:xmpp-session:session", function(event) - log("debug", "Client requesting a session"); event.origin.send(st.reply(event.stanza)); return true; end);