diff --git a/xep-0355.xml b/xep-0355.xml index 3530c4ae..f411c33d 100644 --- a/xep-0355.xml +++ b/xep-0355.xml @@ -29,6 +29,24 @@ goffi@jabber.fr + + 0.3 + 2016-08-01 + jp + + + + + 0.2.1 2015-10-15 @@ -96,6 +114,7 @@
  • Delegated namespace — the namespace being managed by an external entity.
  • Filtering attribute — an attribute which must be present in first &IQ; child element to delegate the namespace.
  • Managing entity — the entity which actualy manages the delegated namespace.
  • +
  • Delegating server — the server which delegate the stanzas to the managing entity.
  • Managed entity — an entity which wants to have a namespace of its server delegated to a managing entity.
  • @@ -127,7 +146,7 @@ -

    When a server receives a stanza for a delegated namespace which is either directed to him (no 'to' attribute, or 'to' attribute with its own JID), or directed to the bare JID of the sender (e.g. if 'from' attribute is "juliet@capulet.lit/balcony" and 'to' attribute is "juliet@capulet.lit"), it MUST forward it to the managing entity by replacing the 'to' attribute with the JID of the managing entity:

    +

    When a server receives a stanza for a delegated namespace which is either directed to him (no 'to' attribute, or 'to' attribute with its own JID), or directed to any bare jid (and only bare jid) that it manages (i.e. the domainpart is a domain handled by the server where delegation is activated), it MUST forwards it to the managing entity:

    ]]>

    The server gets this stanza, sees that this namespace is delegated to pubsub.capulet.lit, so it forwards it.

    -

    To forward, an &IQ; stanza of type "set" is used which contain a <delegation/> element (with namespace'urn:xmpp:delegation:1') which in turn contain a <forwarded/> element encapsulating the initial stanza, according to &xep0297;:

    +

    To forward, an &IQ; stanza of type "set" is used which contain a <delegation/> element (with namespace 'urn:xmpp:delegation:1') which in turn contain a <forwarded/> element encapsulating the initial stanza, according to &xep0297;:

    + type='set' + xmlns='jabber:client'> @@ -182,7 +202,8 @@ + type='result' + xmlns='jabber:client'> @@ -203,9 +224,10 @@

    The workflow is fully transparent for Juliet.

    N.B.₁: If the server encounter a delegated namespace and the managing entity is not available, it MUST return an &IQ; stanza of type "error" with an error condition of <service-unavailable/>

    -

    N.B.₂: If the server encounter a delegated namespace but the filtering attribute does not match, it MUST follow its normal behaviour, i.e. it must follow the same behaviour it would have had if the namespace was not delegated at all

    +

    N.B.₂: Similarly, if the managing entity return an &IQ; stanza of type "error", the server must return itself an &IQ; stanza of type "error" with an error condition of <service-unavailable/>

    +

    N.B.₃: If the server encounter a delegated namespace but the filtering attribute does not match, it MUST follow its normal behaviour, i.e. it must follow the same behaviour it would have had if the namespace was not delegated at all

    -

    If a stanza is sent by the managing entity on a managed namespace, the server MUST NOT forward it. This way, the managing entity can use privileged entity to do special treatments.

    +

    If a stanza is sent by the managing entity on a managed namespace, the server MUST NOT forward it. This way, the managing entity can use privileged entity to do specific treatments, a kind of universal plugin (i.e. working with all servers implementing &xep0355; and &xep0356;).

    In the following examples, juliet@capulet.lit has its "jabber:iq:roster" namespace delegated to filter.capulet.lit. filter.capulet.lit is a server agnostic component which filters allowed entities (which can be added to a roster), and sort them in enforced groups.

    + type='set' + xmlns='jabber:client'> @@ -251,7 +274,8 @@ + type='result' + xmlns='jabber:client' /> @@ -363,7 +387,14 @@ ]]> -

    The managing entity can now manage the namespace the same way as in admin mode.

    +
    + +

    The managing entity can now manage the namespace in a similar way as in admin mode but with different rules:

    +
      +
    1. if the stanza is directed to the delegating server (no 'to' attribute, or 'to' attribute with the server own JID), and the 'from' attribute belong to a managed entity (e.g. juliet@capulet.lit/balcony if juliet@capulet.lit is a managed entity) and the namespace of the stanza has been delegated by the managed entity, then the delegating server MUST forward it to the managing entity accepted by the managed entity, in the same way as in admin mode.
    2. +
    3. if the stanza is directed to the bare jid (and only the bare jid) of the managed entity (e.g. the 'to' attribute is set to juliet@capulet.lit and the namespace has been delegated by the managed entity, then the server MUST forward it to the managing entity accepted by the managed entity, in the same way as in admin mode, for any 'from' attribute but the jid of the managing entity.
    4. +
    5. in all other cases, the server MUST NOT forward the stanza
    6. +
    @@ -400,7 +431,7 @@

    When a server delegates a namespace to a managing entity, the later can have particular features which must be advertised by the former with disco protocol.

    -

    This is done by using a disco node, which is done the following way: if pubsub.capulet.int manages pubsub namespace, it MUST report that fact in discovery feature, and have a 'urn:xmpp:delegation:1::http://jabber.org/protocol/pubsub' node which reports the managed features.

    The node name is obtained by concatenating this XEP namespace (urn:xmpp:delegation:1), a '::' separator, and the delegated namespace (here http://jabber.org/protocol/pubsub).
    The server MUST advertise the result in its own discovery answer, and MUST ignore features of its internal component (here internal PubSub service).

    +

    This is done by using a disco node, which is built in the following way: if pubsub.capulet.int manages pubsub namespace, it MUST report that fact in discovery feature, and have a 'urn:xmpp:delegation:1::http://jabber.org/protocol/pubsub' node which reports the managed features.

    The node name is obtained by concatenating this XEP namespace (urn:xmpp:delegation:1), a '::' separator, and the delegated namespace (here http://jabber.org/protocol/pubsub).
    The server MUST advertise the result in its own discovery answer, and MUST ignore features of its internal component (here internal PubSub service).

    In the following example, the capulet.int server delegates its internal PEP component to pubsub.capulet.int. capulet.int only supports REQUIRED PubSub features and auto-create, while pubsub.capulet.int supports REQUIRED PubSub features and publish-options, but not auto-create.
    juliet@capulet.int asks its server what it is capable of, she is specially interested in PubSub capabilities.

    - + ... @@ -538,6 +568,9 @@
    + +

    Extensions of Service Discovery as specified in &xep0128; follow the same rules: for the delegated namespace, internal extensions MUST be removed and extensions of managing entity MUST be included instead.

    +
    @@ -546,7 +579,7 @@
  • In client mode, server MAY keep delegations granted to an entity by a client from one session to an other, but if it does so, it MUST provide configuration like explained in the suitable section. If server offers this feature, it SHOULD add a field directly in configuration commands.
  • If a client can't check or revoke delegations (i.e. it doesn't support &xep0050;) when granting them, the server MUST NOT keep granted delegations from one session to an other, and delegations will be asked on each new session.
  • If delegations are changed during a session, server MUST notify managing entity of the new delegations, like in client delegation request use case.
  • -
  • If delegations are kept between sessions in client mode, and the managing entity is not available, the server MUST return an &IQ; error with condition <service-unavailable/> when a delegated namespace is requested, like explained in "Server Forwards Delegated &IQ; Stanza" section.
  • +
  • If delegations are kept between sessions in client mode, and the managing entity is not available or return an error, the server MUST return an &IQ; error with condition <service-unavailable/> when a delegated namespace is requested, like explained in "Server Forwards Delegated &IQ; Stanza" section.
  • The namespace of this XEP (urn:xmpp:delegation:1) MUST NOT be delegated. If an entity requests it, the server MUST return a &forbidden; error.
  • @@ -633,6 +666,6 @@

    This XEP is linked with &xep0356; and works in a similar way.

    The client mode delegation mechanism is inspired from &xep0321; permission request.

    Thanks to Adrien Cossa for his typos/style corrections

    -

    Thanks to Philipp Hancke, Dave Cridland, Kurt Zeilenga and Sergey Dobrov for their feedbacks.

    +

    Thanks to Philipp Hancke, Dave Cridland, Kurt Zeilenga, Sergey Dobrov and Анна Мухаррам for their feedbacks.