[standards-jig] Re: JEP-0016 (Server-Based Privacy Rules)

Jean-Louis Seguineau/EXC/TEC jean-louis.seguineau at antepo.com
Fri Nov 15 09:38:17 UTC 2002


Hi,

I am glad that is coming to the surface again, as I had proposed changes
along these lines long ago :)

I would also like to point out that the current behaviour for list updates
that obliged the client to send the whole list at once is particularly
inadequate for small footprint devices (wireless). If one removes the
obligation to process the item in a specific order, and introduce default
list behaviour then it becomes possible to update items individually.

This how list management was proposed:

1 -    Adding a control list and specifying its default behaviour
The following protocol segments illustrate the exchange of packets between
the client application and the server in order to specify the defualt
behaviour of the control list:

1.1        Client add a list and sets the control list default


<iq type="set" id="0">
    <query xmlns="xmpp:iq:privacy">
        <list name="work" type="deny"/>
            <message/>
            <presence/>
            <iq/>
        </list>
    </query>
</iq>

Note: In this case the default behaviour is to deny all messages, presence
and iq packets.


<iq type="set" id="0">
    <query xmlns="xmpp:iq:privacy">
        <list name="work" type="deny"/>
            <presence/>
            <iq>
                <ns>jabber:iq:oop</ns>
                <ns>xmpp:iq:antepo</ns>
            </iq>
        </list>
    </query>
</iq>

Note: In this case the default behaviour is to deny all presence packets,
and jabber:iq:oob  and xmpp:iq:antepo iq packets.

1.2        Server Replies to the control list default


<iq type="result" id="0"/>


2 -    Removing a control list
The following protocol segments illustrate how a client application would
remove a control list.

2.1        Client requests Removal of control list


<iq type="set" id="0">
    <query xmlns="jabber:iq:privacy">
        <list name="home" type="remove"/>
    </query>
</iq>

2.2        Server replies to Remove list Request


<iq type="result" id="0"/>

3 -    Retrieving a control list default behaviour
The following protocol segments illustrate the exchange of packets between
the client application and the server in order to retrieve the control list:

3.1        Client requests all control lists


<iq type="get" id="1">
    <query xmlns="jabber:iq:privacy">
        <list/>
    </query>
</iq>

3.2        Server replies to the control lists Request


<iq type="result" id="1">
    <query xmlns="jabber:iq:privacy">
        <active name="work"/>
        <list name="work" type="deny"/>
            <message/>
            <presence/>
            <iq/>
        </list>
        <list name="home" type="deny"/>
            <message/>
            <presence/>
        </list>
    </query>
</iq>

3.3        Client requests a named control list


<iq type="get" id="2">
    <query xmlns="jabber:iq:privacy">
        <list name="work"/>
    </query>
</iq>

3.4        Server replies to the named control list Request


<iq type="result" id="2">
    <query xmlns="jabber:iq:privacy">
        <list name="work" type="deny"/>
            <message/>
            <presence/>
            <iq/>
        </list>
    </query>
</iq>

4 -    Managing the active control list
4.1        Client requests the active control list


<iq type="get" id="0">
    <query xmlns="jabber:iq:privacy">
        <active/>
    </query>
</iq>

4.2        Server Replies to the control list Request


<iq type="result" id="0">
    <query xmlns="jabber:iq:privacy">
        <active name="work"/>
    </query>
</iq>

4.3        Client sets the active control list

<iq type="set" id="1">
    <query xmlns="jabber:iq:privacy">
        <active name="work"/>
    </query>
</iq>

4.4        Server Replies to the control list Request

<iq type="result" id="1"/>

4.5        Client sets no active control list

<iq type="set" id="2">
    <query xmlns="jabber:iq:privacy">
        <active/>
    </query>
</iq>

4.6        Server Replies to the no active control list Request

<iq type="result" id="2"/>




----- Original Message -----
Robert Norris standards-jig at jabber.org
Fri, 15 Nov 2002 09:52:47 +1100

  a.. Previous message: [standards-jig] JEP-0016 (Server-Based Privacy
Rules)
  b.. Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

----------------------------------------------------------------------------
----

--kvUQC+jR9YzypDnK
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

> Or can I add/change several lists in one query?  Current jabberd2 say tha=
t this
> not acceptable, but I see in JEP-0016 this:
>=20
>         ...Each <query/> element would have one or more <list> elements w=
hich
>         would contain the information for an entire zebra list. The <quer=
y/>
>         element also contains an <active> element which contains the name=
 of
>         the currently active zebra list...

JEP-0016 has a few problems. I've had some discussions with pgmillard,
and we've summarised the required changes as follows:

1. The client can set a default list in addition to the active list. The
   active list is bound to the session, but the default list is bound to
   the user. If the user has a session, then that sessions active list
   is used. If the session doesn't have an active list, or there are no
   sessions for the user, then the default list is used. If none of
   these, then allow everything.

2. The list is processed when a packet arrives, _before_ any other
   processing is done on the packet (eg offline, s10n, presence, etc).

3. In an IQ set, the client can only update lists, or set active/default
   lists - it can't do both at once. If it tries to, the server should
   return a 406.

4. For the future, we may want to look at seperating presence blocking
   from subscription (presence types "subscribe", "unsubscribe",
   "subscribed", "unsubscribed") blocking.

jabberd2 implements these changes. What this basically means for client
authors:

 - you can now set a "default" list, by including <default name=3D'foo'/>
   in your iq set (just like the active list). This list will take
   effect if there are no sessions online, or the current session has
   not set an active list.

 - in an iq set, you can either modify lists, or set the active and
   default lists - not both.

pgm, I understand that you're busy atm. Let me know if you'd like me to
document and submit an update to the JEP.

Rob.

--=20
Robert Norris                                       GPG: 1024D/FC18E6C2
Email+Jabber: rob at cataclysm.cx                Web: http://cataclysm.cx/










More information about the Standards mailing list