# HG changeset patch # User Matthew Wild # Date 1224963261 -3600 # Node ID 744fafa8b7009f7ac9e25d68a2877cd5816229c7 # Parent c51246bc679d7168e86919abb714e02b641c66db Log when an incoming dialback verification request is an invalid key for our domain diff -r c51246bc679d -r 744fafa8b700 core/stanza_router.lua --- a/core/stanza_router.lua Sat Oct 25 18:21:34 2008 +0100 +++ b/core/stanza_router.lua Sat Oct 25 20:34:21 2008 +0100 @@ -114,9 +114,12 @@ print(tostring(origin.to_host), tostring(origin.from_host)) -- FIXME: Grr, ejabberd breaks this one too?? it is black and white in XEP-220 example 34 --if attr.from ~= origin.to_host then error("invalid-from"); end - local type = "invalid"; + local type; if s2s_verify_dialback(attr.id, attr.from, attr.to, stanza[1]) then type = "valid" + else + type = "invalid" + log("warn", "Asked to verify a dialback key that was incorrect. An imposter is claiming to be %s?", attr.to); end origin.send(format("%s", attr.to, attr.from, attr.id, type, stanza[1])); elseif stanza.name == "result" and origin.type == "s2sin_unauthed" then