Initial published version approved by the XMPP Council.
0.0.12015-06-01fs
First draft.
The usage of non-Stanza top-level XMPP stream elements is steadily increasing in the last years. Starting with Stream Management (XEP-0198)XEP-0198: Stream Management <https://xmpp.org/extensions/xep-0198.html>., 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 6120RFC 6120: Extensible Messaging and Presence Protocol (XMPP): Core <http://tools.ietf.org/html/rfc6120>. § 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.
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.
zlib
]]>]]>]]>
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.
Nonzas MUST NOT be routed, i.e. they are only exchanged between the two endpoints of an XMPP stream.
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)XEP-0220: Server Dialback <https://xmpp.org/extensions/xep-0220.html>..
As noted, Nonzas MUST NOT get routed, because this could introduce the ability for third parties to spoof them.
This document requires no interaction with the Internet Assigned Numbers Authority (IANA)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/>..
This document requires no interaction with XMPP RegistrarThe 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/>..