Privileges¶
Note
“XEP-0356: Privileged Entity” only works for XMPP users using the same server as matteridge, e.g., eve@example.org on mattermost.example.org.
Setting up matteridge as a privileged entity (XEP-0356) is optional, but nice to have. It improves user experience with a few “cherry on top” features. By configuring your XMPP server such that matteridge is a privileged entity, matteridge can:
automatically add/remove “puppet contacts” from the XMPP roster of matteridge users,
reflect on the XMPP side messages sent by users via official Mattermost apps,
synchronize other actions done via official Mattermost apps, such as marking messages as read, using emoji reactions, retracting messages, sending files…
automatically add XMPP bookmarks (XEP-0402) for MUCs (XEP-0045).
Server-specific instructions¶
Prosŏdy¶
Install the mod_privilege community module with:
prosodyctl install --server=https://modules.prosody.im/rocks/ mod_privilege
In prosody.cfg.lua, add mod_privilege to the modules_enabled list, and
declare matteridge privileges in the appropriate virtualhost block:
local _privileges = {
roster = "both";
message = "outgoing";
iq = {
["http://jabber.org/protocol/pubsub"] = "both";
["http://jabber.org/protocol/pubsub#owner"] = "set";
}
};
VirtualHost "example.org"
privileged_entities = {
["mattermost.example.org"] = _privileges;
}
Then either restart the prosody server, or reload the config. You might need to use mod_reload_component, and activate/deactivate hosts for all changes to be taken into account (restarting prosody is the easiest way to go).
ejabberd¶
acl:
slidge_acl:
server:
- "mattermost.example.org"
access_rules:
slidge_rule:
- allow: slidge_acl
modules:
mod_privilege:
roster:
both: slidge_rule
message:
outgoing: slidge_rule
iq:
"http://jabber.org/protocol/pubsub":
both: slidge_rule
"http://jabber.org/protocol/pubsub#owner":
set: slidge_rule
mod_roster:
versioning: true
Next step¶
Learn about about matteridge’s configuration to tune its behaviour to your liking.