Spam/abuse reports in XMPP

XMPP supports reporting JIDs and messages as spam or abuse. The sending and receiving of such reports is an important part of helping the network learn and react to problems.

Users

If you receive spam or other abusive messages, use your app to block and report it.

Reporting is currently supported by:

Conversations

In Conversations and derivatives (such as Cheogram, Monocles and Snikket):

Do not reply to incoming spam. Long-press on the spam message and choose ‘Report’.

Alternatively, you can press ‘Block’ at the bottom of the chat when a stranger messages you. If you do not see ‘Block’ but instead the ‘Add back’ button, you can long-press on that to access the block/report option.

Server operators

Receiving reports from your users

Allowing your users to submit reports is the first step. Currently only Prosody supports this.

Prosody

Enable mod_spam_reporting:

modules_enabled = {
    ---
    "spam_reporting";
    ---
}

On its own this module is not very useful, as it only logs the report and it can easily be missed. Keep reading for how to enable Prosody to act on these reports automatically.

Receiving reports from the network

Ensure you have an abuse contact published via XEP-0157 so that you can receive reports from other entities on the network. This is supported by all popular server implementations.

ejabberd

Use mod_disco and set the server_info option:

server_info:
  -
    modules: all
    name: abuse-addresses
    urls: ["xmpp:admin@example.com"]

Prosody

Use mod_server_contact_info and set the contact_info option:

contact_info = {
  abuse = { "xmpp:admin@example.com" };
}

Sending reports to the network

If you or your users receive spam/abuse, many clients support sending a report to their server. The server can then forward that report to the appropriate places.

Currently only Prosody is known to support this.

Forwarding reports

There are two main places to forward reports to:

Server configuration

Prosody

Use the community module mod_report_forward to forward reports.

modules_enabled = {
    ---
    "report_forward";
    ---
}

-- Send a report to the origin server
report_forward_to_origin = true

-- Also send a copy of the report to xmppbl.org's reporting service
report_forward_to = {
    "submit@reports.xmppbl.org";
}