[cl-xmpp-devel] cl-xmpp with usocket patch

Erik Huelsmann ehuels at gmail.com
Fri Jul 11 22:47:22 UTC 2008


On Fri, Jul 11, 2008 at 8:49 PM, Burguz Omonov <burguzomo at hotmail.com> wrote:
> Hi guys,
>  Sorry, the hotmail broke the xml content in my previous messages. I posted
> the full execution log and the packet content as it was posted over the
> wire, here:
>
> http://paste.lisp.org/display/63550
>
> I tested it both with jabber server (the ID and password inside the script
> are actual ID and password that I used) and local ejabber server, and I am
> getting the same output in both cases.
>
> For some reason the server responds with error code 503/service unavailable
> to authentication request with the script, while I am able to successefully
> login using regular jabber client or a small client that I wrote using gloox
> library.  I'll probably need to compare how different the actual requests
> look on the wire..
>
>> Yeah, that sounds like a plain end-of-file situation, where the server
>> closed the connection.
>>
>> That's why it's not very helpful to see just the error message. Please
>> show complete test code, so that errors in that code can be pointed out.
>
> (require :cl-xmpp)
> (defparameter *connection* (xmpp:connect :hostname "jabber.org"))
> (xmpp:auth *connection* "clxmpp" "clxmpp" "res")
> (xmpp:message *connection* "fygrave at gmail.com" "ssup")
> (xmpp:receive-stanza-loop *connection*)
>
> I used both defparameter and defvar here. Doesn't change the situation much.

No, the problem is with the protocol that cl-xmpp uses to get you
authenticated: looking at the output, it's using an auth2 tag, but
when reading rfc3920 there definitely is no auth2 tag; also, the rfc
requires the use of SASL for actual authentication, whereas your code
(and the library) don't.

However, using (require :cl-xmpp-sasl) alone doesn't do the trick. So,
I'm now trying to figure out how the SASL code is meant to be used.

One problem I spotted already is the fact that the allowed
auth-mechanisms are not cached/remembered anywhere, meaning that
actually choosing one (versus hard-coding) isn't possible now. I
believe that the connection APIs may need to be rewritten to support
the RFC completely.

I hope that explains a bit why you're seeing these problems.

Bye,

Erik.



More information about the cl-xmpp-devel mailing list