[jdev] Messages to unsubscribed contacts

Tomasz Sterna tomek at xiaoka.com
Sat Dec 8 18:06:41 CST 2007

On So, 2007-12-08 at 19:01 +0100, Robin Redeker wrote:
> User A sends a message to the bare JID of user B which is not subscribed.
> User B answers to the full JID of user A.

IIRC this full-jid chat binding is discouraged and messages should
always be exchanged between bare JIDs.
If you want to hold to a specific conversation thread, use the <thread/>

> First question: Is the full JID
> of user B transmitted in that message? (I guess it is).

It sure is.

http://www.xmpp.org/internet-drafts/draft-saintandre-rfc3920bis-04.html#stanzas-attributes-from-c2s  Client-to-Server Streams
1. When the server receives an XML stanza from a client and the stanza
does not include a 'from' attribute, the server MUST add a 'from'
attribute to the stanza, where the value of the 'from' attribute is the
full JID (<node at domain/resource>) determined by the server for the
connected resource that generated the stanza, or the bare JID
(<node at domain>) in the case of subscription-related presence stanzas;

> What if user B went offline?

Standard highest resource fallback, or offline storage if none found.

> Should messages to unsubscribed contacts generally go to the bare JID?

IIRC all messages should go to bare JID. Even in the case of mutual

The rationale is, that it's up to receiving party to decide where it
wants to receive messages (via resource priority), not the sending party
(via resource used).

  /\_./o__ Tomasz Sterna
 (/^/(_^^'  Xiaoka.com
._.(_.)_  XMPP: smoku at xiaoka.com

More information about the JDev mailing list