diff options
author | Kim Alvefur <zash@zash.se> | 2018-08-04 03:31:21 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2018-08-04 03:31:21 +0200 |
commit | 4310c5f921348d4a34f826d17c7f74de7c4b79b6 (patch) | |
tree | ca86fb9af1eb399f3e081734e0712ff532440e01 /plugins/mod_pubsub/mod_pubsub.lua | |
parent | b4e05514d2f3cfaf0b1466b2c983808c6a96498f (diff) | |
download | prosody-4310c5f921348d4a34f826d17c7f74de7c4b79b6.tar.gz prosody-4310c5f921348d4a34f826d17c7f74de7c4b79b6.zip |
mod_pubsub: Restrict access model to 'whitelist' and 'open'
'presence' and 'roster' makes more sense for PEP
'auithorize' needs additional code for authorization flow
Diffstat (limited to 'plugins/mod_pubsub/mod_pubsub.lua')
-rw-r--r-- | plugins/mod_pubsub/mod_pubsub.lua | 3 |
1 files changed, 3 insertions, 0 deletions
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 |