This commit is contained in:
Peter Saint-Andre 2013-05-22 12:36:47 -06:00
parent 9214f124e5
commit cae9f3e394
1 changed files with 49 additions and 14 deletions

View File

@ -27,6 +27,12 @@
<email>lance@lance.im</email>
<jid>lance@lance.im</jid>
</author>
<revision>
<version>0.0.2</version>
<date>2013-05-21</date>
<initials>lance</initials>
<remark><p>Incorporated feedback.</p></remark>
</revision>
<revision>
<version>0.0.1</version>
<date>2013-05-08</date>
@ -41,20 +47,33 @@
<section1 topic='Discovering support' anchor='disco'>
<p>If a server supports JID prep queries, it MUST specify the 'urn:xmpp:jidprep:tmp' feature in its service discovery information features as specified in &xep0030; and the Entity Capabilities profile specified in &xep0115;.</p>
<example caption='Client checks for support by the server'><![CDATA[
<iq type='get'
from='juliet@capulet.lit/balcony'
id='info1'>
<query xmlns='http://jabber.org/protocol/disco#info'/>
<iq type="get"
to="capulet.lit"
from="juliet@capulet.lit/balcony"
id="info1">
<query xmlns="http://jabber.org/protocol/disco#info"/>
</iq>]]></example>
<example caption='Server advertises support for JID prep queries'><![CDATA[
<iq type='result'
to='juliet@capulet.lit/balcony'
from='capulet.lit'
id='info1'>
<query xmlns='http://jabber.org/protocol/disco#info'>
...
<feature var='urn:xmpp:jidprep:tmp'/>
...
<iq type="result"
to="juliet@capulet.lit/balcony"
from="capulet.lit"
id="info1">
<query xmlns="http://jabber.org/protocol/disco#info">
...
<feature var="urn:xmpp:jidprep:tmp"/>
...
</query>
</iq>]]></example>
<p>The JID prep service MAY be supported through the use of an external component (&xep0114;); in which case, the component MUST return an identity of "component/jidprep" in addition to the "urn:xmpp:jidprep:tmp" feature.</p>
<example caption='Server component advertises support for JID prep queries'><![CDATA[
<iq type="result"
to="juliet@capulet.lit/balcony"
from="jidprep.capulet.lit"
id="info2">
<query xmlns="http://jabber.org/protocol/disco#info">
<identity category="component" type="jidprep" />
...
<feature var="urn:xmpp:jidprep:tmp" />
</query>
</iq>]]></example>
</section1>
@ -92,7 +111,7 @@
<section1 topic="Implementation Notes" anchor='impl'>
<p>If a client has the ability to perform the prepping and normalization process itself, it SHOULD NOT make a JID prep request to the server.</p>
<p>Upon a successful response, the client SHOULD cache the result, mapping the original JID to the normalized version.</p>
<p>In order to reduce the number of queries made by clients, the server SHOULD ensure that any JID slots understood by the server (e.g. the to and from attributes, roster item JIDs, etc) are properly normalized.</p>
<p>In order to reduce the number of queries made by clients, the server MUST enforce normalization rules for any JID slots understood by the server (e.g. the to and from attributes, roster item JIDs, etc).<note>This requirement is intended to be subsumed by the requirements introduced in &rfc6122bis;</note></p>
</section1>
<section1 topic='Security Considerations' anchor='security'>
<p>As the process for normalizing a JID can be resource intensive, there is a possibility for denial of service attacks. A server MAY rate limit the number of requests to prevent such attacks. Likewise, the server MAY only respond to requests from users that are local to the server.</p>
@ -110,7 +129,23 @@
<section2 topic='Protocol Versioning' anchor='registrar-versioning'>
&NSVER;
</section2>
<section2 topic='Service Discovery Category/Type' anchor='registrar-disco'>
<p>The &REGISTRAR; includes a category of "component" in its registry of Service Discovery identities (see &DISCOCATEGORIES;); as a result of this document, the Registrar includes a type of "jidprep" to that category.</p>
<p>The registry submission is as follows:</p>
<code><![CDATA[
<category>
<name>component</name>
<type>
<name>jidprep</name>
<desc>
A server component that offers a JID prepping
and normalization service to constrained clients.
</desc>
<doc>XEP-XXXX</doc>
</type>
</category>
]]></code>
</section2>
</section1>
<section1 topic='XML Schema' anchor='schema'>
<code><![CDATA[