mirror of
https://github.com/moparisthebest/xeps
synced 2024-11-21 16:55:07 -05:00
Refactored SIDs client-id from attribute to element.
This commit is contained in:
parent
353f30abfe
commit
611eb46c65
39
xep-0359.xml
39
xep-0359.xml
@ -19,13 +19,25 @@
|
||||
</dependencies>
|
||||
<supersedes/>
|
||||
<supersededby/>
|
||||
<shortname>NOT_YET_ASSIGNED (suggested: sid)</shortname>
|
||||
<shortname>stanza-id</shortname>
|
||||
<author>
|
||||
<firstname>Florian</firstname>
|
||||
<surname>Schmaus</surname>
|
||||
<email>flo@geekplace.eu</email>
|
||||
<jid>flo@geekplace.eu</jid>
|
||||
</author>
|
||||
<revision>
|
||||
<version>0.2</version>
|
||||
<date>2015-09-18</date>
|
||||
<initials>fs</initials>
|
||||
<remark>
|
||||
<ul>
|
||||
<li>Refactored client-id from attribute to element.</li>
|
||||
<li>Set short name to 'stanza-id'.</li>
|
||||
<li>Clarified that SID elements must not have additional content.</li>
|
||||
</ul>
|
||||
</remark>
|
||||
</revision>
|
||||
<revision>
|
||||
<version>0.1</version>
|
||||
<date>2015-07-14</date>
|
||||
@ -67,17 +79,17 @@
|
||||
</section2>
|
||||
<section2 topic='Client generated stanza IDs' anchor='client-id'>
|
||||
<p>
|
||||
Some use cases require the client to generate the stanza ID. In this case, the client MUST use 'client-id' as attribute name for the ID.
|
||||
Some use cases require the client to generate the stanza ID. In this case, the client MUST use the 'client-id' element.
|
||||
</p>
|
||||
<example caption='A message stanza with the stanza ID extension.'><![CDATA[
|
||||
<message xmlns='jabber:client'
|
||||
to='room@muc.example.org'
|
||||
type='groupchat'>
|
||||
<body>Typical body text</body>
|
||||
<stanza-id xmlns='urn:xmpp:sid:0' client-id='de305d54-75b4-431b-adb2-eb6b9e546013'/>
|
||||
<client-id xmlns='urn:xmpp:sid:0' id='de305d54-75b4-431b-adb2-eb6b9e546013'/>
|
||||
</message>]]></example>
|
||||
<p>
|
||||
The server MAY add an 'id' attribute to the stanza-id element. In that case, it MUST preserve the content of the 'client-id' attribute.
|
||||
The server or component MAY add a stanza-id element. In that case, it MUST preserve the content of the 'client-id' element.
|
||||
</p>
|
||||
<example caption='A message stanza with the stanza ID extension.'><![CDATA[
|
||||
<message xmlns='jabber:client'
|
||||
@ -86,27 +98,24 @@
|
||||
<body>Typical body text</body>
|
||||
<stanza-id xmlns='urn:xmpp:sid:0'
|
||||
id='new-id-overrides-client-id'
|
||||
by='room@muc.example.org'
|
||||
client-id='de305d54-75b4-431b-adb2-eb6b9e546013'/>
|
||||
by='room@muc.example.org'/>
|
||||
<client-id xmlns='urn:xmpp:sid:0' id='de305d54-75b4-431b-adb2-eb6b9e546013'/>
|
||||
</message>]]></example>
|
||||
<p>
|
||||
Otherwise, if the server does not override the ID, it MAY omit the 'client-id' attribute.
|
||||
</p>
|
||||
</section2>
|
||||
</section1>
|
||||
<section1 topic='Business Rules' anchor='rules'>
|
||||
<ol>
|
||||
<li>XMPP entities, which are routing stanzas, MUST NOT strip stanza-id elements from message stanzas.</li>
|
||||
<li>The values of the 'id' (and 'client-id') attribute SHOULD be unpredictable.</li>
|
||||
<li>Stanza ID generating entities, which encounter a <stanza-id/> element where 'id' (and 'client-id') is already set and where the 'by' attribute matches their own JID, MUST ignore the existing value of 'id' and override it.</li>
|
||||
<li>XMPP entities, which are routing stanzas, MUST NOT strip any elements qualified by the 'urn:xmpp:sid:0' namespace from message stanzas. They SHOULD however ensure that those elements contain only the attributes defined herein, and take approribate countermeasures if this is not the case (e.g. removing those attributes).</li>
|
||||
<li>The values of the 'id' attribute SHOULD be unpredictable.</li>
|
||||
<li>Stanza ID generating entities, which encounter a <stanza-id/> element where 'id' is already set and where the 'by' attribute matches their own JID, MUST ignore the existing value of 'id' and override it.</li>
|
||||
<li>Stanzas MUST posses, in the direct child level of the stanza, at most one 'stanza-id' extension element with the same JID as value of the 'by' attribute.</li>
|
||||
<li>Stanza ID extension elements which have a 'id' attribute MUST also have the 'by' attribute set.</li>
|
||||
<li>Stanza ID extension elements MUST either posses a 'id' attribute, a 'client-id' attribute or both.</li>
|
||||
<li>Every <stanza-id> extension element MUST have the 'id' attribute and the 'by' attribute set.</li>
|
||||
<li>Every <stanza-id> and <client-id> extension element MUST always posses an 'id' attribute and MUST NOT have any child elements or text content.</li>
|
||||
<li>The value of the 'by' attribute MUST be a normalized JID as defined in &rfc6122;</li>
|
||||
</ol>
|
||||
</section1>
|
||||
<section1 topic='Security Considerations' anchor='security'>
|
||||
<p>The value of the 'id' attribute should not provide any further information besides the opaque ID itself. Entities observing the value MUST NOT be able to infer any information from it, e.g. the size of the message archive. The value of 'id' and 'client-id' MUST be considered as non-secret values.</p>
|
||||
<p>The value of the 'id' attribute should not provide any further information besides the opaque ID itself. Entities observing the value MUST NOT be able to infer any information from it, e.g. the size of the message archive. The value of 'id' MUST be considered as non-secret values.</p>
|
||||
</section1>
|
||||
<section1 topic='IANA Considerations' anchor='iana'>
|
||||
<p>This document requires no interaction with &IANA;.</p>
|
||||
|
Loading…
Reference in New Issue
Block a user