[jdev] JEP-0106 - Jid Escaping

Peter Saint-Andre stpeter at jabber.org
Thu Apr 28 13:15:53 CDT 2005


On Thu, Apr 28, 2005 at 02:55:47PM -0300, Hernan Tylim wrote:

> For the sametime transport that I am developing I thought on 
> implementing JEP-0106 but I found it insufficient so I would like to ask 
> the list if my understanding of the JEP was correct.
> 
> Is it correct that JEP-106 only escapes 10 characters? (<space>, ", #, 
> &, ', /, :, <, > and @) If I understood correctly they are the only ten 
> characters not allowed by NODEPREP but allowed by STRINGPREP. 

Nine characters -- # is allowed in an XMPP node identifier.

> But what 
> if we need to escape a character that is not allowed by STRINGPREP ?

What character? The stringprep profiles used by XMPP are pretty liberal
in the characters they allow.

> Moreover, I noticed that my Jabber Server automatically lowercase the 
> JIDs 

Yes, US-ASCII characters in JIDs are "lowercased" (actually case-folded,
in accordance with stringprep). 

> and given that Sametime usernames are case sensitive I needed to 
> escape also all uppercase letters. 

Ick. 

> Does JEP-106 cover this case ? If not, why not ?

Not yet, probably because we didn't think about the need to handle
foreign addresses that are case-sensitive for US-ASCII characters.
Obviously the intent of JEP-0106 was to handle characters that are not
allowed by nodeprep, not to provide a mechanism for getting around the
nodeprep/stringprep rules themselves.

It seems that we may need to work on this some more. One possibility 
is to change MUST NOT to SHOULD NOT regarding which characters can be
transformed using JEP-0106, but I am not sure that's a good idea.
Further thought required....

Peter




More information about the JDev mailing list