diff options
author | Matthew Wild <mwild1@gmail.com> | 2010-03-14 03:06:19 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2010-03-14 03:06:19 +0000 |
commit | a81dc4028b418c0374bbdb56583b40472dbe8693 (patch) | |
tree | 03c9cda3faac5618a8fd7111743313a768d6c480 /net | |
parent | c1cb6b9e9b87dfb2f068aa01ab1fb955852c5360 (diff) | |
download | prosody-a81dc4028b418c0374bbdb56583b40472dbe8693.tar.gz prosody-a81dc4028b418c0374bbdb56583b40472dbe8693.zip |
net.xmppcomponent_listener: Log invalid XML received from components (as we already do for c2s/s2s)
Diffstat (limited to 'net')
-rw-r--r-- | net/xmppcomponent_listener.lua | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/xmppcomponent_listener.lua b/net/xmppcomponent_listener.lua index c9a0d70b..7b8ab95a 100644 --- a/net/xmppcomponent_listener.lua +++ b/net/xmppcomponent_listener.lua @@ -164,6 +164,7 @@ function component_listener.onincoming(conn, data) function session.data(conn, data) local ok, err = parser:parse(data); if ok then return; end + log("debug", "Received invalid XML (%s) %d bytes: %s", tostring(err), #data, data:sub(1, 300):gsub("[\r\n]+", " "):gsub("[%z\1-\31]", "_")); session:close("xml-not-well-formed"); end |