From 4310c5f921348d4a34f826d17c7f74de7c4b79b6 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Sat, 4 Aug 2018 03:31:21 +0200 Subject: mod_pubsub: Restrict access model to 'whitelist' and 'open' 'presence' and 'roster' makes more sense for PEP 'auithorize' needs additional code for authorization flow --- plugins/mod_pubsub/mod_pubsub.lua | 3 +++ 1 file changed, 3 insertions(+) (limited to 'plugins/mod_pubsub') diff --git a/plugins/mod_pubsub/mod_pubsub.lua b/plugins/mod_pubsub/mod_pubsub.lua index 18bdf17f..83ff0897 100644 --- a/plugins/mod_pubsub/mod_pubsub.lua +++ b/plugins/mod_pubsub/mod_pubsub.lua @@ -75,6 +75,9 @@ function check_node_config(node, actor, new_config) -- luacheck: ignore 212/acto if (new_config["max_items"] or 1) > max_max_items then return false; end + if new_config["access_model"] ~= "whitelist" and new_config["access_model"] ~= "open" then + return false; + end return true; end -- cgit v1.2.3