From 1173ee03d3daede409447b6eb049c1ca06145f50 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sun, 18 Oct 2015 14:00:15 +0200 Subject: MUC: Reject muc:admin query with missing child --- plugins/muc/muc.lib.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua index cb182fec..7db463e5 100644 --- a/plugins/muc/muc.lib.lua +++ b/plugins/muc/muc.lib.lua @@ -723,6 +723,9 @@ end function room_mt:handle_admin_query_set_command(origin, stanza) local item = stanza.tags[1].tags[1]; + if not item then + origin.send(st.error_reply(stanza, "cancel", "bad-request")); + end if item.attr.jid then -- Validate provided JID item.attr.jid = jid_prep(item.attr.jid); if not item.attr.jid then -- cgit v1.2.3