1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-11-25 10:42:19 -05:00
This commit is contained in:
Peter Saint-Andre 2013-05-22 12:36:47 -06:00
parent 9214f124e5
commit cae9f3e394

View File

@ -27,6 +27,12 @@
<email>lance@lance.im</email> <email>lance@lance.im</email>
<jid>lance@lance.im</jid> <jid>lance@lance.im</jid>
</author> </author>
<revision>
<version>0.0.2</version>
<date>2013-05-21</date>
<initials>lance</initials>
<remark><p>Incorporated feedback.</p></remark>
</revision>
<revision> <revision>
<version>0.0.1</version> <version>0.0.1</version>
<date>2013-05-08</date> <date>2013-05-08</date>
@ -41,20 +47,33 @@
<section1 topic='Discovering support' anchor='disco'> <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> <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[ <example caption='Client checks for support by the server'><![CDATA[
<iq type='get' <iq type="get"
from='juliet@capulet.lit/balcony' to="capulet.lit"
id='info1'> from="juliet@capulet.lit/balcony"
<query xmlns='http://jabber.org/protocol/disco#info'/> id="info1">
<query xmlns="http://jabber.org/protocol/disco#info"/>
</iq>]]></example> </iq>]]></example>
<example caption='Server advertises support for JID prep queries'><![CDATA[ <example caption='Server advertises support for JID prep queries'><![CDATA[
<iq type='result' <iq type="result"
to='juliet@capulet.lit/balcony' to="juliet@capulet.lit/balcony"
from='capulet.lit' from="capulet.lit"
id='info1'> id="info1">
<query xmlns='http://jabber.org/protocol/disco#info'> <query xmlns="http://jabber.org/protocol/disco#info">
... ...
<feature var='urn:xmpp:jidprep:tmp'/> <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> </query>
</iq>]]></example> </iq>]]></example>
</section1> </section1>
@ -92,7 +111,7 @@
<section1 topic="Implementation Notes" anchor='impl'> <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>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>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>
<section1 topic='Security Considerations' anchor='security'> <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> <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'> <section2 topic='Protocol Versioning' anchor='registrar-versioning'>
&NSVER; &NSVER;
</section2> </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>
<section1 topic='XML Schema' anchor='schema'> <section1 topic='XML Schema' anchor='schema'>
<code><![CDATA[ <code><![CDATA[