hannesm / jackline

minimalistic secure XMPP client in OCaml
BSD 2-Clause "Simplified" License
250 stars 20 forks source link

BadRequest exception from XMPP #152

Open smondet opened 7 years ago

smondet commented 7 years ago

Trying to /connect, I see the new "user" appear on Gajim for less than a second; then it disconnects, with an exception but no other error message:

11:53:28 *** connecting *** to talker.to (188.68.34.213 on port 5222)
11:53:29 *** TLS session info *** (TLS_1_2 TLS_RSA_WITH_AES_256_CBC_SHA256)
11:53:30 XXXXX@talker.to/Jackline: [_>o] (now online)
11:53:30 XXXXX@talker.to/Gajim: [_>o] (now online)
11:53:30 *** async error *** XMPP.Make(M)(XmlParser)(IDCallback).BadRequest
hannesm commented 7 years ago

since you can reproduce, could you run jackline -d true, which will create an out.txt in your current working directory. If you send the last line(s) from that file, they should be sufficient to see the problem.

thanks!

smondet commented 7 years ago

the last line is:

[11:35:24] IN TLS: <presence from='XXXXX@talker.to/Jackcline'><priority>10</priority></presence><iq id='lx42' type='set'><query ver='12' xmlns='jabber:iq:roster'><item jid='gbahelzb55mikilljkxz' ask='subscribe' subscription='none'/></query></iq>
hannesm commented 7 years ago

I think I need some more context (maybe up to the last OUT TLS)? Is gbahelzb55mikilljkxz a random string or did you mask a real jabber id with a random string for privacy issues?

hannesm commented 7 years ago

unable to find the root source of the issue -- but the jid returned in the roster (not containing any @ character) is strange. I guess this will be fixed once a more pure XMPP library is in place (which may take a while)...