PATCH: Proper namespaces handling in DJabberd

Daniel Ruoso daniel at
Wed Jun 10 20:11:22 UTC 2009

Em Qua, 2009-06-10 às 13:00 -0700, Martin Atkins escreveu:
> And you are sending this element as a direct child of a message stanza? 

Yes, it is a direct child of the stanza element.

> Can you share some code that illustrates the problem?

Unfortunally, I only have code that is integrated with the system. But I
was able to reproduce it with netcat...

> I'm surprised to hear that namespaces aren't working since we use them 
> as part of the switching mechanism to determine the type of an iq stanza.

Ok, namespaces are partly working. If you only use namespaces without
using prefixes, it works fine. The problem is when you use prefixes to
declare the namespaces of the elements, which, when you have unqualified
elements in the document, is actually a requirement.

> I'm happy to have a whack at writing a test for this, but right now I'm 
> not entirely sure what I'm testing; we already have some tests that use 
> namespaces, such as the vcard one you made minor alterations to in your 
> patch, so I don't know what additional test we need to catch the bug 
> you've found.

The test is to send a document that use namespace with prefixes, and
have the namespaces with prefixes in the other side. The example XML
message I sent illustrates the problem in detail.


More information about the Djabberd mailing list