# HG changeset patch # User Matthew Wild # Date 1487716831 0 # Node ID cca9de97526b32656bce68d4696b1cd8e70dabcc # Parent 76f03d514b133b4f7848ae83d6a42769361c2b00 mod_firewall: Fix FORWARD action to include a 'from' address and depend on core_post_stanza diff -r 76f03d514b13 -r cca9de97526b mod_firewall/actions.lib.lua --- a/mod_firewall/actions.lib.lua Tue Feb 21 13:37:44 2017 +0000 +++ b/mod_firewall/actions.lib.lua Tue Feb 21 22:40:31 2017 +0000 @@ -157,11 +157,11 @@ function action_handlers.FORWARD(where) local code = [[ - local newstanza = st.stanza("message", { to = %q }):tag("forwarded", { xmlns = "urn:xmpp:forward:0" }); + local newstanza = st.stanza("message", { to = %q, from = session.host }):tag("forwarded", { xmlns = "urn:xmpp:forward:0" }); local tmp_stanza = st.clone(stanza); tmp_stanza.attr.xmlns = "jabber:client"; newstanza:add_child(tmp_stanza); core_post_stanza(session, newstanza); ]]; - return code:format(where); + return code:format(where), { "core_post_stanza" }; end function action_handlers.LOG(string)