[ejabberd] rc1: PEP, presence. Bugs?

Gabriel Soto gabsoto at gmail.com
Mon Feb 11 20:59:04 MSK 2008


On Feb 11, 2008 12:23 PM, Christophe Romain <cromain at process-one.net> wrote:
> The patch for 1 (EJAB-518) has been committed for ejabberd-2.0.0

Great!

Just for the sake of documenting, this was the problematic sequence
related to issue #2.
>From the user's perspective, the following actions where performed:

1. userA gets invisible
2. userA blocks userB (blocks outbound presence to userB's JID)
3. userA unblocks userB
4. userA gets visible

Then, userB still sees userA as unavailable.

Here's what happens more in detail. The implementation was a little
rough, so the client was doing some things unnecessarily.

1. userA gets invisible:
   1a. userA sends global presence of type unavailable
   1b. userA activates the 'invisible' privacy list
   1c. userA sends global available presence (not broadcasted due to
the active privacy list)

2. userA blocks userB:
   2a. userA sends directed presence unavailable to userB
       (this is not necessary actually, as userA is already invisible)
   2b. userA edits privacy lists to include the new blocked user

3. userA unblocks userB:
   3a. userA edits privacy lists to exclude userB

4. userA gets visible:
   4a. userA activates the 'default' privacy list (contains only the
blocked users)
   4b. userA sends global available presence

The problem was with the steps 2a and 4b. That sequence is the one I
wrote in my first message. 4b is a presence broadcast that doesn't
seem to reach userB.
However, it was solved easily by omitting the step 2a.

Another thing I noticed (not a big deal really) is that ejabberd
doesn't automatically send unavailable presence to a contact when
outbound presence is blocked for that user, as stated at the end of
section 2.11 of XEP-0016
(http://www.xmpp.org/extensions/xep-0016.html#protocol-presenceout).

Gabriel.


More information about the ejabberd mailing list