aboutsummaryrefslogtreecommitdiff
path: root/include/ejabberd_commands.hrl
diff options
context:
space:
mode:
authorMickael Remond <mremond@process-one.net>2016-07-23 17:57:44 +0200
committerMickael Remond <mremond@process-one.net>2016-07-23 18:21:45 +0200
commit68555ff4666588bba68e372b66d5bdbef3849838 (patch)
tree0dcf2d4bdbbf0d796a7a37578529c0fa576e1cca /include/ejabberd_commands.hrl
parentError when not authorized should be 403 (diff)
Add support for checking access rules conformance for commands
Diffstat (limited to '')
-rw-r--r--include/ejabberd_commands.hrl5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/ejabberd_commands.hrl b/include/ejabberd_commands.hrl
index 2b4eca581..bafd93a4d 100644
--- a/include/ejabberd_commands.hrl
+++ b/include/ejabberd_commands.hrl
@@ -38,19 +38,24 @@
function :: atom() | '_',
args = [] :: [aterm()] | '_' | '$1' | '$2',
policy = restricted :: open | restricted | admin | user,
+ access_rules = [] :: [atom()],
result = {res, rescode} :: rterm() | '_' | '$2',
args_desc = none :: none | [string()] | '_',
result_desc = none :: none | string() | '_',
args_example = none :: none | [any()] | '_',
result_example = none :: any()}).
+%% TODO Fix me: Type is not up to date
-type ejabberd_commands() :: #ejabberd_commands{name :: atom(),
tags :: [atom()],
desc :: string(),
longdesc :: string(),
+ version :: integer(),
module :: atom(),
function :: atom(),
args :: [aterm()],
+ policy :: open | restricted | admin | user,
+ access_rules :: [atom()],
result :: rterm()}.
%% @type ejabberd_commands() = #ejabberd_commands{