powered by Jive Software

OpenFire 3.3.2 + JSJaC 1.0 communication issues

Hi all, I’m currently investigating setting up a web based application that uses Jabber as its underlying message transport and integrating it with an existing web application, to this end im looking at deploying OpenFire and JSJaC. However, i seem to be having some grief getting JSJaC to communicate with openfire. Ive had a broad dig across the web but nothing seems to cover the specific problems im having.

For context, im running a self contained OpenFire 3.3.2 on Windows XP, with Apache 2.2.4 serving the JSJaC library and example ‘simpleclient.html’ and proxy requests to localhost/http-bind/ to my install of openfire at jabber.localhost:8080/http-bind/

When JSJaC attempts to make the initial connection request it gets an http 400 error back:

Request POST data:


Error 400

+h2. HTTP ERROR: 400



[Powered by Jetty:// | http://jetty.mortbay.org/]

Whenever a request like this is sent, the openfire warn.log has a single line similar to

2007.09.04 12:04:59 Error parsing user request.

If anyone has an suggestions about how to go about resolving this situation that would be greatly appreciated.

Kind regards,

Andrew Brehaut

The author of JSJaC provided me with the following;


OpenFire is not compatible with JSJaC 1.0 as it implements BOSH v1.6 and

OF doesn’t.

In order to make it work set JSJaCHBC_USE_BOSH_VER at

src/JSJaCHttpBindingConnection.js to ‘false’;

Second make sure to force NON SASL authentication. To do this edit

simpleclient.html and look for ‘doLogin’. When it comes to passing

‘oArg’ to con.connect make sure it has

oArg.authtype = ‘nonsasl’;


This worked properly for me.

Andrew Brehaut

Hi Andrew,

i’m still have the same error when i try to connect JSJaC with OpenFire, can you describe me your configuration wich work properly for you.


Tarik Arrad

I’m getting this exact same error. The fact of the matter is that when I put OpenFire’s HTTP-BIND (ssl) on the port that’s being proxied to, I get this error:

h1. Proxy Error
The proxy server received an invalid
response from an upstream server.
The proxy server could not handle the request GET /http-bind/.
Reason: Error reading from remote server

When I put OpenFire’s HTTP-BIND (non-ssl version) on the port that’s being proxied to, I get this error:

Powered by Jetty://

So – unless JWChat is making some weird request besides just GET like my browser makes, OpenFire is the reason for JWChat not working, not JSJaC (which nowadays has all those vars combined into one file, jsjac.js).

So the question is: What’s up with http-binding in OpenFire? Is it broken, or am I doing something blatantly wrong? My config goes almost exactly like this:


Notice the original poster is asking the same thing this thread addresses… Can someone answer this?

We use SSL, but JwChat connects to the normal XMPP port (5222), maybe that is your issue.

Unless I’m totally off base here, no, it doesn’t. JWChat asks for /http-bind/, it doesn’t make a TCP connection to the actual service, that’s the whole point of http-binding, isn’t it?

It makes a connection to wherever you point /http-bind/. In my case, I point it to http://chatserver:ssl-http-binding-port/http-bind/. That’s when I get the first error I posted. When I point it to http://chatserver:http-binding-port/http-bind/, I get the second error. When I point it to https://chatserver:ssl-http-binding-port/http-bind/ I get an Internal Server Error.

Anybody got the answer to this? TIA

This is the exact problem I am having.