mirror of
https://github.com/moparisthebest/xeps
synced 2024-11-24 10:12:19 -05:00
177 lines
7.8 KiB
XML
177 lines
7.8 KiB
XML
|
<?xml version='1.0' encoding='UTF-8'?>
|
||
|
<!DOCTYPE jep SYSTEM '../jep.dtd' [
|
||
|
<!ENTITY % ents SYSTEM '../jep.ent'>
|
||
|
%ents;
|
||
|
]>
|
||
|
<?xml-stylesheet type='text/xsl' href='../jep.xsl'?>
|
||
|
<jep>
|
||
|
<header>
|
||
|
<title>Jingle DTMF</title>
|
||
|
<abstract>This document specifies an XML format for encapsulating DTMF data in informational messages sent within the context of Jingle audio interactions.</abstract>
|
||
|
&LEGALNOTICE;
|
||
|
<number>0181</number>
|
||
|
<status>Experimental</status>
|
||
|
<type>Standards Track</type>
|
||
|
<jig>Standards JIG</jig>
|
||
|
<approver>Council</approver>
|
||
|
<dependencies>
|
||
|
<spec>XMPP Core</spec>
|
||
|
<spec>JEP-0166</spec>
|
||
|
</dependencies>
|
||
|
<supersedes/>
|
||
|
<supersededby/>
|
||
|
<shortname>jingle-dtmf</shortname>
|
||
|
&stpeter;
|
||
|
&seanegan;
|
||
|
<revision>
|
||
|
<version>0.3</version>
|
||
|
<date>2006-07-12</date>
|
||
|
<initials>se/psa</initials>
|
||
|
<remark><p>Updated syntax to use action and code attributes rather than tone element in order to provide real-time interaction; specified how to negotiate use of the RFC 2833 format via content-info messages.</p></remark>
|
||
|
</revision>
|
||
|
<revision>
|
||
|
<version>0.2</version>
|
||
|
<date>2006-06-29</date>
|
||
|
<initials>psa</initials>
|
||
|
<remark><p>Allowed characters A, B, C, and D; updated schema.</p></remark>
|
||
|
</revision>
|
||
|
<revision>
|
||
|
<version>0.1</version>
|
||
|
<date>2006-03-23</date>
|
||
|
<initials>psa</initials>
|
||
|
<remark><p>Initial JEP version.</p></remark>
|
||
|
</revision>
|
||
|
<revision>
|
||
|
<version>0.0.1</version>
|
||
|
<date>2006-03-21</date>
|
||
|
<initials>psa</initials>
|
||
|
<remark>First draft.</remark>
|
||
|
</revision>
|
||
|
</header>
|
||
|
<section1 topic='Introduction' anchor='intro'>
|
||
|
<p>Traditional telephony systems use Dual Tone Multi-Frequency (DTMF) for dialing and to issue commands such as those used in Interactive Voice Response (IVR) applications. Internet telephony systems also use DTMF tones for interoperability with the public switched telephone network (PSTN). XMPP clients that use &jep0166; for voice chat (see &jep0167;) MUST use the protocol described in this document if they wish to support DTMF.</p>
|
||
|
</section1>
|
||
|
<section1 topic='Tone Format' anchor='format'>
|
||
|
<p>The format for the XML DTMF format is as follows:</p>
|
||
|
<example caption="Basic DTMF Format"><![CDATA[
|
||
|
<dtmf xmlns='http://jabber.org/protocol/info/dtmf'
|
||
|
action='button-down'
|
||
|
code='integer'
|
||
|
/>
|
||
|
]]></example>
|
||
|
<p>The <dtmf/> element SHOULD possess one 'action' attribute, which MUST be either "button-up" or "button-down", specifying whether the button is being depressed or released. This allows DTMF tones to be reconstructed in real-time. If the 'action' attribute is not included, the recipient MUST assume this to be a "button-down" event, and imply a "button-up" event after a reasonable timeout (100 milliseconds is RECOMMENDED) or when another DMTF event is received.</p>
|
||
|
<p>Unless, the 'action' attribute is 'button-up', the <dmtf/> element MUST possess a 'code' attribute that specifies the tone to be generated. The value of the 'code' attribute SHOULD be one the following characters: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, #, and * -- however, the characters A, B, C, and D MAY be sent as well. <note>Although A, B, C, and D were originally defined as part of DTMF, they were never deployed to telephony consumers and were used only for control purposes at private branch exchanges (PBXs) and central office operator stations; however, they are used in certain non-telephony applications of DTMF, such as ham radio.</note></p>
|
||
|
<p>The <dtmf> element SHOULD be sent as the payload of a Jingle content-info message as illustrated in the following example.</p>
|
||
|
<example caption="Entity Sends DTMF Message"><![CDATA[
|
||
|
<iq from='juliet@capulet.com/balcony'
|
||
|
to='ivr.shakespeare.lit'
|
||
|
id='dtmf1'
|
||
|
type='set'>
|
||
|
<jingle xmlns='http://jabber.org/protocol/jingle'
|
||
|
action='content-info'
|
||
|
initiator='juliet@capulet.com/balcony'
|
||
|
sid='a73sjjvkla37jfea'>
|
||
|
<dtmf xmlns='http://jabber.org/protocol/jingle/info/dtmf'
|
||
|
code='7'
|
||
|
action='button-up'
|
||
|
/>
|
||
|
</jingle>
|
||
|
</iq>
|
||
|
]]></example>
|
||
|
</section1>
|
||
|
<section1 topic='Negotiating RFC 2833' anchor='2833'>
|
||
|
<p>Some applications may want to stream Jingle voice RTP directly to a non-XMPP entity, such as a SIP phone. In this scenario, DTMF needs to be sent in the content channel. Jingle DTMF allows to Jingle entities to negotiate whether to send RTP over the XMPP signalling channel as described above, or over the content channel, using RFC 2833.</p>
|
||
|
<p>To request that the voice session switches to RFC 2833, a client sends a <dtmf-method/> element, qualified by the 'http://jabber.org/protocol/info/dmtf' namespace as the payload of a Jingle content-info message:</p>
|
||
|
<example caption="Client requests using RFC 2833"><![CDATA[
|
||
|
<iq from='juliet@capulet.com/balcony'
|
||
|
to='ivr.shakespeare.lit'
|
||
|
id='dtmf2'
|
||
|
type='set'>
|
||
|
<jingle xmlns='http://jabber.org/protocol/jingle'
|
||
|
action='content-info'
|
||
|
initiator='juliet@capulet.com/balcony'
|
||
|
sid='a73sjjvkla37jfea'>
|
||
|
<dtmf-method xmlns='http://jabber.org/protocol/jingle/info/dtmf' method='rtp'>
|
||
|
</jingle>
|
||
|
</iq>
|
||
|
]]></example>
|
||
|
<p>The dtmf-method element MUST contain one 'method' attribute, the value of which SHOULD be either 'rtp' or 'xmpp'.</p>
|
||
|
<p>If the recipient supports the requested DTMF method, it SHOULD send an empty IQ result:</p>
|
||
|
<example caption="Recipient acknowledges request"><![CDATA[
|
||
|
<iq from='ivr.shakespeare.lit'
|
||
|
to='juliet@capulet.com/balcony'
|
||
|
id='dtmf2'
|
||
|
type='result'/>
|
||
|
]]></example>
|
||
|
<p>If the recipient does not supoprt the requested DTMF method, it MUST reply with a lt;feature-not-implemented/> error with a DTMF-specific error condition of <unsupported-dtmf-method/>:</p>
|
||
|
<example caption="Recipient refuses request"><![CDATA[
|
||
|
<iq from='ivr.shakespeare.lit'
|
||
|
to='juliet@capulet.com/balcony'
|
||
|
id='dtmf2'
|
||
|
type='error'>
|
||
|
<error type='cancel'>
|
||
|
<feature-not-implemented xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/>
|
||
|
<unsupported-dtmf-method xmlns='http://jabber.org/protocol/jingle/info/dtmf#errors'/>
|
||
|
</error>
|
||
|
</iq>
|
||
|
]]></example>
|
||
|
</section1>
|
||
|
|
||
|
<section1 topic='Security Considerations' anchor='security'>
|
||
|
<p>This document introduces no known security vulnerabilities.</p>
|
||
|
</section1>
|
||
|
<section1 topic='IANA Considerations' anchor='iana'>
|
||
|
<p>This JEP requires no interaction with &IANA;.</p>
|
||
|
</section1>
|
||
|
<section1 topic='Jabber Registrar Considerations' anchor='registrar'>
|
||
|
<section2 topic='Protocol Namespaces' anchor='registrar-ns'>
|
||
|
<p>The ®ISTRAR; shall include 'http://jabber.org/protocol/jingle/info/dtmf' in its registry of protocol namespaces.</p>
|
||
|
</section2>
|
||
|
</section1>
|
||
|
<section1 topic='XML Schema' anchor='schema'>
|
||
|
<code><![CDATA[
|
||
|
<?xml version='1.0' encoding='UTF-8'?>
|
||
|
|
||
|
<xs:schema
|
||
|
xmlns:xs='http://www.w3.org/2001/XMLSchema'
|
||
|
targetNamespace='http://jabber.org/protocol/jingle/info/dtmf'
|
||
|
xmlns='http://jabber.org/protocol/jingle/info/dtmf'
|
||
|
elementFormDefault='qualified'>
|
||
|
|
||
|
<xs:element name='dtmf'>
|
||
|
<xs:complexType>
|
||
|
<xs:sequence>
|
||
|
<xs:element ref='tone' minOccurs='1' maxOccurs='unbounded'/>
|
||
|
</xs:sequence>
|
||
|
</xs:complexType>
|
||
|
</xs:element>
|
||
|
|
||
|
<xs:element name='tone'>
|
||
|
<xs:complexType>
|
||
|
<xs:simpleContent>
|
||
|
<xs:extension base='empty'>
|
||
|
<xs:attribute name='code' type='DTMFString' use='required'/>
|
||
|
<xs:attribute name='duration' type='xs:positiveInteger' use='optional'/>
|
||
|
</xs:extension>
|
||
|
</xs:simpleContent>
|
||
|
</xs:complexType>
|
||
|
</xs:element>
|
||
|
</xs:element>
|
||
|
|
||
|
<xs:simpleType name="DTMFString">
|
||
|
<xs:restriction base="xs:string">
|
||
|
<xs:pattern value="(#|\*|0|1|2|3|4|5|6|7|8|9|A|B|C|D)*" />
|
||
|
</xs:restriction>
|
||
|
</xs:simpleType>
|
||
|
|
||
|
<xs:simpleType name='empty'>
|
||
|
<xs:restriction base='xs:string'>
|
||
|
<xs:enumeration value=''/>
|
||
|
</xs:restriction>
|
||
|
</xs:simpleType>
|
||
|
|
||
|
</xs:schema>
|
||
|
]]></code>
|
||
|
</section1>
|
||
|
</jep>
|