Strophe Update: Public Repo, Authentication Testing, and More


It’s taking a bit longer than planned to whip Strophe into releasable shape, but work is progressing well.  Since the last update, I have made a new and better Trac instance for the project, made a public SVN repository for the code, added SASL ANONYMOUS support to both libstrophe and Strophe.js, fixed DIGEST-MD5 authentication with ejabberd, did compatibility testing for both libraries, and wrote up a basic Strophe.js example.  Still to come are TLS fixes for libstrophe, porting the libstrophe documentation to Natural Docs, working around a BOSH bug with Tigase, and writing up some examples.

On a related note, Matthew Wild is working on an XMPP library for Lua built on top of libstrophe.

Also, remember to vote for my XMPP talk and panel at SXSW 2009.

UPDATED 8/26: It turns out Tigase and Openfire are smarter than the other XMPP servers with DIGEST-MD5 authentication, and that it wasn’t a bug at all.  My apologies (kudos) to the Tigase and Openfire teams.  The issue is now fixed in trunk.


12 Responses to “Strophe Update: Public Repo, Authentication Testing, and More”

  1. Don’t you think it is better to report the problem or a bug to the Tigase developers rather than work around the bug?
    I looked at the bug description on your tracker but to be honest I don’t understand it. Could you put there a reference to a Bosh specification section describing the case?

    According to the spec XEP-0206 stream features SHOULD be sent “upon receiving any request with the ‘xmpp:restart’ attribute set to “true””.

  2. Woooo! Congrats on whipping Strophe into shape. I know we at Seesmic are looking at it very closely for some of our javascript needs.

    Keep up the great work!

  3. 3 metajack

    @artur: Of course it is better, and likely I will do both. I apologize for being a little slow to report the bug upstream. Strophe.js was originally written before xmpp:restart was in the spec, and the latest version of the spec changes the SHOULD to MUST, so we are probably both a little in violation. Openfire has the same issue as well.

    @bear: Thanks!

  4. I wasn’t aware of the last Bosh changes but xmpp:restart always triggers stream features response from the Tigase Biosh implementation so I think it is still fine with the change to MUST.

    If your library however, doesn’t send xmpp_restart it won’t receive stream features after authentication.

    Regarding the bug reports. Simple e-mail or message on the forum is completely fine.

  5. Glad to hear progress is being made. I am beginning work on adding chat (plus a little something extra) to new app for a major company… all NDA for now. I’ve decided to build it on strophe.js. I’ll send an update when it’s live.

    Thank you for the public SVN repo. I’ll be following along! Cheers!


  6. Excellent! I guess it’s time to play 🙂 The example, although very basic, helps me a lot. Thanks!

    I’m actually, planning to use strophe for a somewhat big project too.

    I have a spur-of-the moment question: does strophe works with ejabberd BOSH, Tigase, etc. ? I mean, if the server states support for BOSH then can I assume that strophe will work with it?

  7. 7 metajack

    @artur: Great to know that if xmpp:restart is sent that it will immediately send stream:features. I’ll play with that.

    @keith: Looking forward to seeing the cool stuff you’re making!

    @favio: I’m planning to do some more in-depth examples. I already have built an echobot example that I need to clean up before posting publicly.

    Can you tell us anything about your big project?

    As for BOSH support, I am currently doing compatibility testing on all the different BOSH servers. I know there are a few lurking issues, since we have tested mainly with Punjab, which is what Chesspark built and uses. If you find any specific bugs, please report them at

  8. @metajack: Please be aware: Bosh specification clearly states that the data from the server may not be available “immediately”. The Bosh connection manager waits for the response data from the server but “NOT longer than the time specified by the client in the ‘wait’ attribute of its Session Creation Request”. Therefore response data (like stream features) may be sent in one of next BODY elements.

    I think you can clarify your blog entry now saying that your are working around the bug in Tigase server as according to my understanding there is no bug in the Tigase server behavior.

    By the way. I am now working on the XMPP Test public area. The place where you can test your software – both client side and the server side. This is Tigase cluster installation integrated with the Drupal CMS. You can register a test account and login using any client. I am going to put there all Tigase components for tests including Bosh, PubSub, MUC, and all other standard and non-standard.

    If you are interested please have a look at:

  9. @metajack more examples? Great! I’m one of those people that learn most by reading, modifying, and running examples 🙂

    The project I’m working on is a variation for Fididel. I can’t say much because of the nda issue, but I’m sure you will “get it” if you check the website.

    About BOSH support on different servers: yeah, I tried a bit with strophe and ejabberd’s BOSH, but didn’t work and couldn’t troubleshoot the issue. Then tried with jsjac and it worked. So that’s why I want to use Punjab, I’m not experienced but I sense strophe gives me more flexibility than jsjac.

  10. I concur with Favio; more examples would be great! I am using Openfire 3.4.5 and the basic example only ever gives me connecting, SENT, and disconnecting. I have revision 519 checked out. I do not appear to ever get connected.

    Perhaps, I am misunderstanding the basic example, but my gut is telling me that Openfire is the issue… and, a bit of research, reveals that Openfire versions prior to version 3.6, which is still in beta, do not completely support the BOSH protocol. Most notably it does only does Polling and does not keep the connection open…

    I’m still not exactly clear on what Punjab is, but can I run it between my JS client and Openfire to provide full BOSH support?


  11. 11 metajack

    @Artur: I found the bug (it was a pair of bugs in Strophe), and have updated the post. However, I’m having trouble with xep 78 digest auth. I have double checked I am following the spec, but Tigase always tells me that I’m not authorized.

    @Favio: Great. Let us know when it launches. I am planning to have a “Who is using Strophe?” page, and I’d love to have Fididel on there. I’ll probably start testing ejabberd’s BOSH tomorrow now that I’ve updated Strophe to use the latest version of the protocol.

    @Keith: I have been using to test Openfire, but I haven’t gotten it to work the last day or so. Punjab can’t connect to it for some reason. If anyone has another openfire server that I can get an account on, I’d apreciate it. You’ll definitely need BOSH support. HTTP polling is not supported by Strophe.

    Punjab is a BOSH connection manager. The difference between it and the connection managers in openfire or ejabberd is that it works with any jabber server. The one at chesspark will let you connect to any XMPP server on the internet.

  12. @metajack: And you are testing your against what Tigase installation? Have you installed own Tigase server for this?

%d bloggers like this: