XEP-0360: Nonzas (are not Stanzas)

This specification defines the term "Nonza", describing every top level stream element that is not a Stanza.
Florian Schmaus
© 2015 – 2017 XMPP Standards Foundation. SEE LEGAL NOTICES.


WARNING: This document has been Rejected by the XMPP Council. Implementation of the protocol described herein is not recommended under any circumstances.
Standards Track
0.2 (2017-09-11)
Document Lifecycle
  1. Experimental
  2. Proposed
  3. Rejected
  4. Stable
  5. Final

1. Introduction

The usage of non-Stanza top-level XMPP stream elements is steadily increasing in the last years. Starting with Stream Management (XEP-0198) [1], one of the earliest XEPs which specified and used additional non-Stanza elements, the XMPP community sees an increasing usage of those elements in submitted specifications. Unlike Stanzas which are specified in RFC 6120 [2] § 4.1 "Stream Fundamentals" and § 8. "XML Stanzas", there is no term and definition provided for them.

This leads to the unfortunate situation where some submitted XEPs erroneous refer to non-Stanza top level stream elements as 'Stanzas'. Thus causing confusion, and opening the door to possible interoperability breakage and security vulnerabilities.

This XEP tries to fix this by providing a term, a definition and declaring some rules for those XMPP stream elements.

2. Nonza Definition

Nonza: A Nonza is every XML element found at the XMPP stream's top level which is not a Stanza. The top level of an XMPP stream is the child XML level beneath the last <stream> opening tag as defined in RFC 6120 § 4.2. "Opening a Stream", i.e. at depth=1 of the stream.

Informal definition: A XMPP stream element is a Nonza, if its element name is not 'message', 'iq' or 'presence'.

The term 'Nonza' originates from the beginning and ending letters of its definition and thus makes it easy to recall that definition: Not a Stanza.

3. Nonza Examples

3.1 Nonzas used before resource binding

Example 1. The Stream Compression (XEP-0138) <compress/> Nonza
<compress xmlns='http://jabber.org/protocol/compress'>

3.2 Nonzas used after resource binding

Example 2. The Stream Management (XEP-0198) <enable/> Nonza
<enable xmlns='urn:xmpp:sm:3'/>
Example 3. The Client State Indication (XEP-0352) <active/> Nonza
<active xmlns='urn:xmpp:csi:0'/>

4. Use Cases

Nonzas are commonly used when it is not necessary to route the exchanged information behind the endpoints of an XMPP stream. For example, one use case is to control the XMPP stream like it is done in XEP-0198: Stream Management.

Nonzas sent before resource binding, as defined in RFC 6120 § 7., usually follow a request-response pattern. But after the client successfully bound a resource, they are used in a more "asynchronous" fashion, where a 'request' Nonza does not, or at least not immediately, trigger a 'result' Nonza sent back.

5. Business Rules

  1. Nonzas MUST NOT be routed, i.e. they are only exchanged between the two endpoints of an XMPP stream.
  2. Nonzas SHOULD NOT have a 'from' or 'to' attribute.

Note that an exception from 2. are the the widely used <db/> Nonzas defined in Server Dialback (XEP-0220) [3].

6. Security Considerations

As noted, Nonzas MUST NOT get routed, because this could introduce the ability for third parties to spoof them.

7. IANA Considerations

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

8. XMPP Registrar Considerations

This document requires no interaction with XMPP Registrar [5].


Appendix A: Document Information

XMPP Standards Foundation
Standards Track
Last Updated
Approving Body
XMPP Council
Superseded By
Short Name
Source Control

This document in other formats: XML  PDF

Appendix B: Author Information

Florian Schmaus


This XMPP Extension Protocol is copyright © 1999 – 2024 by the XMPP Standards Foundation (XSF).


Permission is hereby granted, free of charge, to any person obtaining a copy of this specification (the "Specification"), to make use of the Specification without restriction, including without limitation the rights to implement the Specification in a software program, deploy the Specification in a network service, and copy, modify, merge, publish, translate, distribute, sublicense, or sell copies of the Specification, and to permit persons to whom the Specification is furnished to do so, subject to the condition that the foregoing copyright notice and this permission notice shall be included in all copies or substantial portions of the Specification. Unless separate permission is granted, modified works that are redistributed shall not contain misleading information regarding the authors, title, number, or publisher of the Specification, and shall not claim endorsement of the modified works by the authors, any organization or project to which the authors belong, or the XMPP Standards Foundation.

Disclaimer of Warranty

## NOTE WELL: This Specification is provided on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. ##

Limitation of Liability

In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall the XMPP Standards Foundation or any author of this Specification be liable for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising from, out of, or in connection with the Specification or the implementation, deployment, or other use of the Specification (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if the XMPP Standards Foundation or such author has been advised of the possibility of such damages.

IPR Conformance

This XMPP Extension Protocol has been contributed in full conformance with the XSF's Intellectual Property Rights Policy (a copy of which can be found at <https://xmpp.org/about/xsf/ipr-policy> or obtained by writing to XMPP Standards Foundation, P.O. Box 787, Parker, CO 80134 USA).

Visual Presentation

The HTML representation (you are looking at) is maintained by the XSF. It is based on the YAML CSS Framework, which is licensed under the terms of the CC-BY-SA 2.0 license.

Appendix D: Relation to XMPP

The Extensible Messaging and Presence Protocol (XMPP) is defined in the XMPP Core (RFC 6120) and XMPP IM (RFC 6121) specifications contributed by the XMPP Standards 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.

Appendix E: Discussion Venue

The primary venue for discussion of XMPP Extension Protocols is the <standards@xmpp.org> discussion list.

Discussion on other xmpp.org discussion lists might also be appropriate; see <https://xmpp.org/community/> for a complete list.

Errata can be sent to <editor@xmpp.org>.

Appendix F: Requirements Conformance

The following requirements 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".

Appendix G: Notes

1. XEP-0198: Stream Management <https://xmpp.org/extensions/xep-0198.html>.

2. RFC 6120: Extensible Messaging and Presence Protocol (XMPP): Core <http://tools.ietf.org/html/rfc6120>.

3. XEP-0220: Server Dialback <https://xmpp.org/extensions/xep-0220.html>.

4. 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/>.

5. The XMPP Registrar maintains a list of reserved protocol namespaces as well as registries of parameters used in the context of XMPP extension protocols approved by the XMPP Standards Foundation. For further information, see <https://xmpp.org/registrar/>.

Appendix H: Revision History

Note: Older versions of this specification might be available at https://xmpp.org/extensions/attic/

  1. Version 0.2 (2017-09-11)
    Defer due to lack of activity.
    XEP Editor (jwi)
  2. Version 0.1 (2015-07-14)

    Initial published version approved by the XMPP Council.

    XEP Editor (mam)
  3. Version 0.0.1 (2015-06-01)

    First draft.


Appendix I: Bib(La)TeX Entry

  title = {Nonzas (are not Stanzas)},
  author = {Schmaus, Florian},
  type = {XEP},
  number = {0360},
  version = {0.2},
  institution = {XMPP Standards Foundation},
  url = {https://xmpp.org/extensions/xep-0360.html},
  date = {2015-06-01/2017-09-11},