XEP-0159: SPIM-Blocking Control

This document defines an XMPP protocol extension that enables clients to control how their servers may block SPIM that is addressed to them. It specifies a default privacy list fall-through action.

WARNING: Consideration of this document has been Deferred by the Jabber Software Foundation. Implementation of the protocol described herein is not recommended.

XEP Information

Status: Deferred
Type: Standards Track
Number: 0159
Version: 0.1
Last Updated: 2005-09-14
Publishing Organization: Jabber Software Foundation
Approving Body: XMPP Council
Dependencies: XMPP Core, XMPP IM, XEP-0030
Supersedes: None
Superseded By: None
Short Name: spim-control
Wiki Page: <http://wiki.jabber.org/index.php/SPIM-Blocking Control (XEP-0159)>

Author Information

Ian Paterson

Email: ian.paterson@clientside.co.uk
JID: ian@zoofy.com

Legal Notice

This XMPP Extension Protocol is copyright 1999 - 2006 by the Jabber Software Foundation (JSF) and is in full conformance with the JSF's Intellectual Property Rights Policy <http://www.xmpp.org/extensions/ipr-policy.shtml>. This material may be distributed only subject to the terms and conditions set forth in the Creative Commons Attribution License (<http://creativecommons.org/licenses/by/2.5/>).

Discussion Venue

The preferred venue for discussion of this document is the Standards-JIG discussion list: <http://mail.jabber.org/mailman/listinfo/standards-jig>.

Relation to XMPP

The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core (RFC 3920) and XMPP IM (RFC 3921) specifications contributed by the Jabber Software Foundation to the Internet Standards Process, which is managed by the Internet Engineering Task Force in accordance with RFC 2026. Any protocol defined in this document has been developed outside the Internet Standards Process and is to be understood as an extension to XMPP rather than as an evolution, development, or modification of XMPP itself.

Conformance Terms

The following keywords as used in this document are to be interpreted as described in RFC 2119: "MUST", "SHALL", "REQUIRED"; "MUST NOT", "SHALL NOT"; "SHOULD", "RECOMMENDED"; "SHOULD NOT", "NOT RECOMMENDED"; "MAY", "OPTIONAL".

Table of Contents

1. Introduction
1.1. Motivation
1.2. Requirements
1.3. Approach
1.4. Note on SPIM Recognition
2. Discovery
3. SPIM Blocking
3.1. Correspondents Lists
3.2. Fall-Through Procedure
3.3. Delay Procedure
4. Configuring Privacy Lists
4.1. Exempting Trusted Groups from SPIM Blocking
4.1.1. Users on Roster
4.1.2. Transports
4.1.3. Users of Trusted Servers
4.2. Exempting Individual Users from SPIM Blocking
4.3. Explicitly Blocking SPIM
4.4. Completely Disabling SPIM Blocking
5. Security Considerations
6. IANA Considerations
7. XMPP Registrar Considerations
7.1. Well-Known Service Discovery Nodes
Revision History

1. Introduction

1.1 Motivation

The appearance of large public IM services based on RFC 3920 [1] and RFC 3921 [2] created an urgent need to implement protocols that discourage the sending of large quantities of IM SPAM (SPIM) from XMPP clients (connected to legitimate servers) and XMPP servers (with virtual clients) -- all hosted on networks of 'zombie' machines. SPIM is defined here as any type of unsolicited XMPP stanza sent by a 'robot' and delivered to a human, including messages and subscription requests. SPIM has the potential to disrupt people even more than SPAM, because each message interrupts the receiver (humans typically filter SPAM in batch mode).

SPIM blocking is more efficiently performed on the receiving server for several reasons:

However, no automated SPIM recognition techniques work perfectly all the time. This document is designed to give users control over the SPIM recognition their servers perform on their behalf.

1.2 Requirements

Clients should be able to:

1.3 Approach

The stanza blocking protocol defined in RFC 3921 allows a client to control explicitly which senders its server must block stanzas from. Such explicit blocking is suitable for privacy control, but not for filtering SPIM.

This document contradicts an assumption expressed in the standard blocking protocol in order to extend client control to SPIM blocking. More specifically, it simply defines a SPIM recognition privacy-list fall-through action that is different from the 'allow' default assumed in RFC 3921. [4]

1.4 Note on SPIM Recognition

The various SPIM recognition procedures that may be employed by the server are beyond the scope of this document. No single measure can differentiate all SPIM perfectly. It is RECOMMENDED that servers implement a combination of complementary SPIM recognition techniques (and other anti-SPIM techniques [5]).

For example, a server could employ traffic and reputation analysis to filter the majority of SPIM, and use Robot Challenges to identify the remainder (feeding what it learns back to the traffic and reputation analysis).

2. Discovery

A client MAY confirm that its server supports SPIM-Blocking Control using Service Discovery [6].

Example 1. Initial Service Discovery Information Request

<iq type='get'
  <query xmlns='http://jabber.org/protocol/disco#info'/>

Example 2. Server Indicates Support

<iq type='result'
  <query xmlns='http://jabber.org/protocol/disco#info'>
    <identity category='im' type='server'/>
    <feature var='http://jabber.org/protocol/spim-control'/>

3. SPIM Blocking

This section specifies server functionality not defined in RFC 3921.

3.1 Correspondents Lists

A server that supports this protocol MAY maintain a separate [7] list of each user's correspondents. Each list contains all the bare JIDs the user has either sent a stanza to or received a stanza from (over the past few weeks or months).

Note: When it blocks a stanza, the server MUST NOT add the 'from' attribute of the stanza to the correspondents list.

Note: The lists of correspondents have a very different function from rosters. Edits are initiated by the server not the client, allowing the lists to be completely transparent to clients.

3.2 Fall-Through Procedure

The server SHOULD perform the following procedures whenever it receives a stanza that falls through the active privacy list of the user it is addressed to without being either allowed or denied:

  1. If the server maintains correspondents lists, and if the bare JID in the 'from' attribute of the received stanza is on the addressed user's correspondents list, then the server SHOULD allow the stanza to be delivered to the user.
  2. Otherwise, the server SHOULD perform one or more SPIM recognition procedures (not defined in this document).
  3. Depending on the result of those procedures, it SHOULD then either allow, deny or delay the delivery of the stanza without informing the sender.

3.3 Delay Procedure

When a SPIM recognition procedure delays delivery of a stanza the server SHOULD store it temporarily.

While delivery is being delayed:

Once delivery of a stanza has been delayed for an implementation-specific length of time, or an implementation-specific number of stanzas from the same sender (or same sending server) are being delayed, the server SHOULD deny delivery of the stanza without informing the sender.

A good example of a delayed SPIM recognition procedure is when servers use the Robot Challenges protocol to confirm whether or not a client is a SPIM robot before denying or allowing the delivery of a stanza from a new correspondent. [9] [10]

4. Configuring Privacy Lists

This informative section requires no client or server functionality beyond that defined in RFC 3921.

4.1 Exempting Trusted Groups from SPIM Blocking

4.1.1 Users on Roster

The client SHOULD use the 'subscription' type to exclude all JIDs on the user's roster from SPIM blocking (see the items with order 20, 30 and 40 in the example below).

4.1.2 Transports

At least in the medium term, clients that use non-XMPP protocols cannot be expected to support interactive SPIM recognition techniques (like Robot Challenges). So, if its server uses interactive techniques, the client MAY use the 'jid' type to ensure its server does not block stanzas arriving from the transports the user has registered with (see the item with order 50 in the example below).

4.1.3 Users of Trusted Servers

If a user believes SPIM will not be sent by users of a particular server (e.g. the user's own corporate server), then the client MAY use the 'jid' type to exclude all these users from SPIM blocking (see the item with order 60 in the example below).

Example 3. Exempting Users from SPIM Blocking

<iq type='set' from='victim@mydomain.com/laptop'>
  <query xmlns='jabber:iq:privacy'>
    <list name='normal'>
      <item type='subscription'
      <item type='subscription'
      <item type='subscription'
      <item type='jid'
      <item type='jid'

4.2 Exempting Individual Users from SPIM Blocking

No SPIM recognition techniques are perfect. Senders are sometimes falsely identified as SPIM bots. (For example, when a server sends Robot Challenges, but the client does not support that protocol.)

In these cases the user MAY ask out-of-band the person he is trying to communicate with to allow communications in one of the following ways:

4.3 Explicitly Blocking SPIM

If stanzas from a SPIM robot running on a zombie domain somehow manage to get past the server's SPIM recognition then the client MAY use the 'jid' type to block one or all JIDs from the domain. (RFC 3921 already enables this functionality.)

Example 4. Blocking SPIM from a Specific Domain

<iq type='set' from='victim@mydomain.com/laptop'>
  <query xmlns='jabber:iq:privacy'>
    <list name='normal'>
      <item type='jid'

4.4 Completely Disabling SPIM Blocking

A client MAY disable server-side SPIM blocking by ensuring the default fall-through action is never applied. It does this simply by including an explicit fall-through item in its active privacy list.

Example 5. Client Disables SPIM Blocking

<iq type='set' from='victim@mydomain.com/laptop'>
  <query xmlns='jabber:iq:privacy'>
    <list name='normal'>
      <item action='allow' order='999'/>

Note: Before a server with existing accounts deploys this protocol, it MAY ensure all users' privacy lists have an explicit fall-through item. As a result, SPIM recognition would be disabled until users choose to switch it on.

5. Security Considerations

If a server implements this protocol and its security is compromised, then the attacker may be able to access the list of all previous correspondants for every user. People are unable to delete their own lists and they may not even be aware that they exist. So servers MUST ensure they protect this sensitive information very carefully.

6. IANA Considerations

This document requires no interaction with the Internet Assigned Numbers Authority (IANA) [12].

7. XMPP Registrar Considerations

7.1 Well-Known Service Discovery Nodes

Upon approval of this document, the XMPP Registrar shall register the following well-known Service Discovery node:


1. RFC 3920: Extensible Messaging and Presence Protocol (XMPP): Core <http://www.ietf.org/rfc/rfc3920.txt>.

2. RFC 3921: Extensible Messaging and Presence Protocol (XMPP): Instant Messaging and Presence <http://www.ietf.org/rfc/rfc3921.txt>.

3. XEP-0158: Robot Challenges <http://www.xmpp.org/extensions/xep-0158.html>.

4. The language used in RFC 3921 Section 10.2 Rule 7 appears to be deliberately vague (informative rather than normative) in order to permit other default fall-through actions. The protocol defined in this document is therefore (arguably) compatible with RFC 3921.

5. Other examples of anti-SPIM policies and protocols include: requiring a user to pass a robot challenge before registering a new account, invite-only and/or out-of-band user account registration, providing a standard protocol for reporting SPIM to both the servers involved, server-to-server connection dialback, karma (client-to-server and server-to-server), legal agreements not to send SPIM during user account registration, and IP blocking.

6. XEP-0030: Service Discovery <http://www.xmpp.org/extensions/xep-0030.html>.

7. If the server were to maintain a single unified list of the correspondents of all its users, then SPIMers would only need to pass a single SPIM recognition test before being allowed to send SPIM to all the server's users.

8. For example, the first time a stanza is delivered the correspondents list will change, typically triggering the immediate delivery of any other delayed stanzas.

9. The very occasional inconvenience of responding to a challenge is small and perfectly acceptable -- especially when compared to the countless robot-generated interruptions people might otherwise have to filter every day.

10. If a human user fails such a robot challenge then his client SHOULD give him the option to resend the stanza immediately.

11. The subscription type SHOULD never be 'none' because RFC 3921 specifies that, for the purposes of blocking, all JIDs not on the roster also have the subscription type 'none'.

12. The Internet Assigned Numbers Authority (IANA) is the central coordinator for the assignment of unique parameter values for Internet protocols, such as port numbers and URI schemes. For further information, see <http://www.iana.org/>.

Revision History

Version 0.1 (2005-09-14)

Initial version. (ip)

Version 0.0.1 (2005-09-08)

First draft. (ip)