Strophe.js and websocket

I am a total newby in Ejabberd... I am trying to setup a basic connection via WebSocket using Strophe.js but I can't seem to get it to work...

Here is the javascript: https://gist.github.com/rastkojokic/2fa83e36e0770fd5f26e
Here is the Ejabberd server config: https://gist.github.com/rastkojokic/e26f044f6088b86e976f
Here is the Strophe's connection object: https://gist.github.com/rastkojokic/17e5e0a64aedd8bd0a07

I have confirmed that I have registered user with username: usr1 and password: psw1.

When I try to submit the authentication I get the bad request (400) response.

Any idea or guideline what am I doing wrong?

Thanks in advance!

Best,
Rastko

To use Strophe with

To use Strophe with websockets I guess your WEBSOCKET_SERVICE url should be `ws://127.0.0.1:5280/websocket` and not ``http://127.0.0.1:5280/websocket`` as you are doing now.

Syndicate content