Abstract: | This specification provides documentation how Server Dialback is used together with Transport Layer Security, and discusses how the security considerations of Dialback are changed by the introduction of TLS and/or DNSSEC. |
Authors: | Philipp Hancke, Dave Cridland |
Copyright: | © 1999 - 2014 XMPP Standards Foundation. SEE LEGAL NOTICES. |
Status: | Experimental |
Type: | Standards Track |
Version: | 0.2 |
Last Updated: | 2014-03-19 |
WARNING: This Standards-Track document is Experimental. Publication as an XMPP Extension Protocol does not imply approval of this proposal by the XMPP Standards Foundation. Implementation of the protocol described herein is encouraged in exploratory implementations, but production systems are advised to carefully consider whether it is appropriate to deploy implementations of this protocol before it advances to a status of Draft.
1. Introduction
2. Protocol
2.1. Dramatis Personae
2.2. Classic Dialback Flow
2.3. XMPP Exchanges in Classic Dialback over TLS
2.4. Dialback without dialback flow
2.5. XMPP Exchanges in Dialback without dialback
3. Security Considerations
3.1. Same Certificate shortcut
3.2. Dialback without dialback shortcut
3.3. DNSSEC
4. IANA Considerations
5. XMPP Registrar Considerations
Appendices
A: Document Information
B: Author Information
C: Legal Notices
D: Relation to XMPP
E: Discussion Venue
F: Requirements Conformance
G: Notes
H: Revision History
Although Server Dialback (XEP-0220) [1] describes dialback as being run before any other negotiation, it is typically run over TLS where supported. This allows it to be used as a simple convenient fallback to X.509 Strong Authentication within the TLS layer, as described in RFC 6120 [2], and also affords greater protection to the exchange.
This document describes these practises, and also describes various functionally equivalent shortcuts to the protocol, including that known as "dialback without dialback".
This document will tell a tale of two servers; orchard.capulet.example is trying to contact home.montague.example. Each server operates a single domain; these are capulet.example and montague.example respectively.
The traditional pattern is shown here:
orchard.capulet. home.montague. example example (as Initiating) (as Receiving Server) Server) ---------------- ------------- | | | [if necessary, | | perform DNS | | lookup on | | Target Domain, | | open TCP | | connection, | | and establish | | stream] | | -----------------> | | (ID D60000229F) | | | | send | capulet.example | dialback key | (as Authoritative | -----(STEP 1)----> | Server) | | ----------------- | | [if necessary, | | | perform DNS | | | lookup on | | | Sender Domain, | | | open TCP | | | connection, | | | and establish | | | stream] | | | -----------------> | | | | | | send | | | verify request | | | ----(STEP 2)-----> | | | | | | send | | | verify response | | | <----(STEP 3)----- | | | | | report | | | dialback result | | | <-----(STEP 4)---- | |
This traditional pattern involves the following protocol exchanges when dialback over TLS is used:
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' from='capulet.example' to='montague.example' version='1.0'>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' id='D60000229F' from='montague.example' to='capulet.example' version='1.0'> <stream:features> <starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'> <required/> </starttls> </stream:features>
<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<proceed xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' from='capulet.example' to='montague.example' version='1.0'>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' id='D60000229F' from='montague.example' to='capulet.example' version='1.0'> <stream:features> <mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'> </mechanisms> </stream:features>
<db:result from='capulet.example' to='montague.example'> b4835385f37fe2895af6c196b59097b16862406db80559900d96bf6fa7d23df3 </db:result>
<db:verify from='montague.example' id='D60000229F' to='capulet.example'> b4835385f37fe2895af6c196b59097b16862406db80559900d96bf6fa7d23df3 </db:verify>
<db:verify from='capulet.example' id='D60000229F' to='montague.example' type='valid'/>
<db:result from='montague.example' to='capulet.example' type='valid'/>
If during the initial connection, home.montague.example is able to determine that the certificate presented is trustworthy, and authenticates orchard.capulet.example as authorized to offer the XMPP service for capulet.example, then the flow can be shortcutted heavily, allowing the entire Authoritative Server process to be elided.
This is particularly useful in cases where the dialback exchange is a subsequent exchange used in piggybacking, as it remains the only solution for piggybacking with strong authentication.
orchard.capulet. home.montague. example example (as Initiating) (as Receiving Server) Server) ---------------- ------------- | | | [if necessary, | | perform DNS | | lookup on | | Target Domain, | | open TCP | | connection, | | and establish | | stream] | | -----------------> | | (ID D60000229F) | | | | send | | dialback key | | -----(STEP 1)----> | | | | | [observe certificate | | trustworthy and | | correct for capulet.example | | as per RFC 6125] | | | report | | dialback result | | <-----(STEP 4)---- |
This traditional pattern involves the following protocol exchanges when dialback over TLS is used:
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' from='capulet.example' to='montague.example' version='1.0'>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' id='D60000229F' from='montague.example' to='capulet.example' version='1.0'> <stream:features> <starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'> <required/> </starttls> </stream:features>
<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<proceed xmlns='urn:ietf:params:xml:ns:xmpp-tls'/>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' from='capulet.example' to='montague.example' version='1.0'>
<stream:stream xmlns:stream='http://etherx.jabber.org/streams' xmlns='jabber:server' id='D60000229F' from='montague.example' to='capulet.example' version='1.0'> <stream:features> <mechanisms xmlns='urn:ietf:params:xml:ns:xmpp-sasl'> <mechanism name='EXTERNAL'/> </mechanisms> </stream:features>
Note that having authenticated the certificate and found it authorized for capulet.example, montague.example has offered EXTERNAL above. It's not clear why capulet.example does not avail itself of the offer below; however it should be noted that EXTERNAL would not be available with piggybacking for example.
<db:result from='capulet.example' to='montague.example'> b4835385f37fe2895af6c196b59097b16862406db80559900d96bf6fa7d23df3 </db:result>
Critically, it is at this point that home.montague.example both authenticates and checks authorization on the certificate, or at least ensure that the certificate presented at this stage matches that presented at the initial handshake.
<db:result from='montague.example' to='capulet.example' type='valid'/> from='montague.example' to='capulet.example' type='valid'/>
With respect to XEP-0220's security considerations, the adaptations in this document add at minimum channel encryption and integrity, which forces an attacker into making an active attack, rather than passive eavesdropping. This raises the cost of an attack significantly. However, unless the certificates are authenticated, there is still a man-in-the-middle attack possible, and the reliance on unauthenticated DNS remains problematic.
Use of the "Same Certificate" shortcut described in XXXX is not thought to materially alter the security profile beyond that described above. In particular, it does not alter the level of trust an implementation may put in authentication.
Use of the "Dialback without dialback" shortcut described in XXXX raises the level of authentication to that of the TLS/SASL-EXTERNAL process described in RFC 6120, and is thought to be indistinguishable from a security standpoint. As such, the security considerations relating to this in RFC 6120 et al apply.
If both SRV and A/AAAA records are protected by DNSSEC, this means that the correct address for the peer can be proven, removing DNS forgery as an attack vector. Without TLS, it is however still possible to mount an array of attacks, including IP spoofing and eavesdropping.
With TLS, however, the situation improves. Since TLS protects against a naïve IP spoofing attack, a routing protocol attack (such as BGP hijacking) is required to forge the server.
In addition, it is of critical importance to check the certificate at the time when the dialback result is received, and not only in the initial handshake. This protects against an attack based around renegotiation.
This document requires no interaction with the Internet Assigned Numbers Authority (IANA) [3].
This document requires no interaction with the XMPP Registrar.
Series: XEP
Number: 0344
Publisher: XMPP Standards Foundation
Status:
Experimental
Type:
Standards Track
Version: 0.2
Last Updated: 2014-03-19
Approving Body: XMPP Council
Dependencies: XMPP Core, XEP-0220
Supersedes: None
Superseded By: None
Short Name: dwd
Source Control:
HTML
This document in other formats:
XML
PDF
Email:
fippo@andyet.com
JabberID:
fippo@goodadvice.pages.de
Email:
dave@cridland.net
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.
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 <http://xmpp.org/about/discuss.shtml> for a complete list.
Errata can be sent to <editor@xmpp.org>.
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".
1. XEP-0220: Server Dialback <http://xmpp.org/extensions/xep-0220.html>.
2. RFC 6120: Extensible Messaging and Presence Protocol (XMPP): Core <http://tools.ietf.org/html/rfc6120>.
3. 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/>.
Note: Older versions of this specification might be available at http://xmpp.org/extensions/attic/
Editorial fixes.
(editor (mam))Initial published version approved by the XMPP Council.
(editor (mam))Changed title and added more security considerations.
(dwd)Added some narrative and a section on dwd.
(dwd)First draft.
(ph)END