setting up with ejabberd http_bind and without punjab?

0 views
Skip to first unread message

Chad

unread,
Mar 9, 2009, 5:59:04 PM3/9/09
to speeqe
Firstly, I think strophe is awesome and I was planning on making a
project relatively similar to speeqe with it. I'm not sure whether
I'm going to base this project on speeqe or start from scratch yet,
but I am certainly trying to use speeqe to figure out how to go about
connecting ejabberd's http-bind with a Django project.

Can speege be setup using only Apache and Ejabberd? Apache will be
used to host django and presumably do something like mod_rewrite from
port 80 to port 5280 on ejabberd. How would I go about setting this
up?

More details about my actual project to come, thanks a lot!

Christopher Zorn

unread,
Mar 10, 2009, 8:12:40 AM3/10/09
to spe...@googlegroups.com

You do not need punjab to run speeqe or any other BOSH client. You will just do a reverse proxy to the ejabberd server in your apache configuration. You can then ignore the punjab step. We really need documentation help with a lot of things in speeqe.



 

Chad Selph

unread,
Mar 10, 2009, 2:22:11 PM3/10/09
to spe...@googlegroups.com, spe...@googlegroups.com
I think I almost had it working last night, if I can get it I will write up a tutorial.

Christopher Zorn

unread,
Mar 10, 2009, 2:27:09 PM3/10/09
to spe...@googlegroups.com
On Tue, Mar 10, 2009 at 2:22 PM, Chad Selph <chad....@gmail.com> wrote:
I think I almost had it working last night, if I can get it I will write up a tutorial.


That would be really cool! Thanks.

 

Chad

unread,
Mar 11, 2009, 3:19:42 AM3/11/09
to speeqe
It may not be until next week before I get much chance to try stuff.
I have a midterm and 6 page paper due tomorrow, (I should probably get
working on that since it's midnight) but next week is spring break.

On Mar 10, 11:27 am, Christopher Zorn <christopher.z...@gmail.com>
wrote:
> On Tue, Mar 10, 2009 at 2:22 PM, Chad Selph <chad.se...@gmail.com> wrote:
> > I think I almost had it working last night, if I can get it I will write up
> > a tutorial.
>
> That would be really cool! Thanks.
>
>
>
>
>
> > On Mar 10, 2009, at 5:12 AM, Christopher Zorn <christopher.z...@gmail.com>
> > wrote:

Christopher Zorn

unread,
Mar 11, 2009, 8:37:55 AM3/11/09
to spe...@googlegroups.com
On Wed, Mar 11, 2009 at 3:19 AM, Chad <chad....@gmail.com> wrote:

It may not be until next week before I get much chance to try stuff.
I have a midterm and 6 page paper due tomorrow, (I should probably get
working on that since it's midnight) but next week is spring break.

I did not mean to indicate you needed to rush. I was just thanking in advance. Take your time and good luck!!
 

Chad

unread,
Mar 20, 2009, 9:47:06 PM3/20/09
to speeqe
I have everything setup but the room gets suck on "Joining room".
That is if I first log in through the interface (logging in works,
ejabberd logs confirm this) but something with the room doesn't...

mod_muc is working fine I can log in to rooms with Adium. not really
sure how to go about debugging this. I don't think anything is being
sent to the jabber server at all, (and with Firebug or Wireshark I
can't see any attempts at requests to the BOSH stuff).

On Mar 11, 5:37 am, Christopher Zorn <christopher.z...@gmail.com>
wrote:

Christopher Zorn

unread,
Mar 23, 2009, 9:23:30 AM3/23/09
to spe...@googlegroups.com
On Fri, Mar 20, 2009 at 9:47 PM, Chad <chad....@gmail.com> wrote:

I have everything setup but the room gets suck on "Joining room".
That is if I first log in through the interface (logging in works,
ejabberd logs confirm this) but something with the room doesn't...

mod_muc is working fine I can log in to rooms with Adium.  not really
sure how to go about debugging this.  I don't think anything is being
sent to the jabber server at all, (and with Firebug or Wireshark I
can't see any attempts at requests to the BOSH stuff).

This could mean your bosh stuff is configured wrong. Could you post your settings files here?


 

vet...@gmail.com

unread,
Mar 28, 2009, 6:17:48 PM3/28/09
to speeqe
On Mar 21, 2:47 am, Chad <chad.se...@gmail.com> wrote:
> I have everything setup but the room gets suck on "Joining room".
> That is if I first log in through the interface (logging in works,
> ejabberd logs confirm this) but something with the room doesn't...
>
> mod_muc is working fine I can log in to rooms with Adium.  not really
> sure how to go about debugging this.  I don't think anything is being
> sent to the jabber server at all, (and with Firebug or Wireshark I
> can't see any attempts at requests to the BOSH stuff).

I have exactly the same problem, using ejabberd+mod_muc+nginx+django
+speeqe+punjab

As you can see, the difference here is that I am trying to use punjab
instead of mod_http_bind.

I can log in, and ejabberd's logs and admin interface acknowledge it,
but when i try to join a chatroom, i get disconnected with an
"Authentication Failure" error.

Could there be a problem specific to ejabberd and mod_muc ?

If you find the solution to your problem, I'd be glad to see it,
thanks.

Nathan Zorn

unread,
Mar 29, 2009, 7:57:46 AM3/29/09
to spe...@googlegroups.com
I have a few questions in order to find out what the problem is.  My first guess is that you are trying to log in anonymously without anonymous sasl configured for your server.  Is this the case? 

If you are able to login with Adium or another client, then its most likely punjab or speeqe that has the issue.  Are you able to use an account created by the speeqe code to login?

vet...@gmail.com

unread,
Mar 29, 2009, 11:03:44 AM3/29/09
to speeqe
On Mar 29, 1:57 pm, Nathan Zorn <nathan.z...@gmail.com> wrote:
> I have a few questions in order to find out what the problem is.  My first
> guess is that you are trying to log in anonymously without anonymous sasl
> configured for your server.  Is this the case?

Oh, that must be the problem, I don't have any anonymous login
activated anywhere in ejabberd's configuration. Does activating it
mean that anyone will be able to log in to my server even if they
don't have an account? I'd like to avoid that as much as possible.

What is ejabberd's correct configuration to be able to use it with
speeqe?
I had only this, which obviously didn't work:

{auth_method, internal}.

I am trying with something like that, but it still doesn't work:

{host_config, "myserver.com", [{auth_method, [internal, anonymous]},
{allow_multiple_connections, false},
{anonymous_protocol, sasl_anon}]}.

> If you are able to login with Adium or another client, then its most likely
> punjab or speeqe that has the issue.  Are you able to use an account created
> by the speeqe code to login?

What is an "account created by the speeqe code"? On my server, I have
only internal accounts, nothing else, and I don't think speeqe has the
authorization to create any account.

vet...@gmail.com

unread,
Mar 29, 2009, 4:07:08 PM3/29/09
to speeqe
I tested a different configuration:

{auth_method, [internal, anonymous]}.
{allow_multiple_connections, false}.
{anonymous_protocol, both}.

But it still doesn't work. I have this message in the logs, maybe it
can help:

D(<0.365.0>:cyrsasl_digest:50) : User login not authorized because
digest-uri seems invalid: "xmpp/"

Nathan Zorn

unread,
Mar 29, 2009, 5:42:37 PM3/29/09
to spe...@googlegroups.com
If anonymous isn't working its either punjab or speeqe.

There is a python script in the speeqeweb directory called httpbclient.py.  Run this script to see if
your punjab setup is working.   Usage is the following:

python httpbclient.py  the...@speeqe.com/rc passwd www.speeqe.com

You should use your jid (don't forget the resource) and password along with the punjab host name.

Let me know if you have luck with this script.  If it works, its something with speeqe code.

vet...@gmail.com

unread,
Mar 29, 2009, 4:34:33 PM3/29/09
to speeqe
Sorry for all the mails, but in fact anonymous login seems to work (i
just found how to test it). I had, in Speeqe, to log out of my jabber
account, then when i tried to join a chatroom, some anonymous account
was created (4287358140123...@myserver.com/
10973155661238357746797820), and I was given some random nickname
(harding47817).

So, now, for the anonymous part, it seems to work. Thanks a lot for
this part of the software, it's going to be usefull.

However, as I have said previously, I am also interested in the non-
anonymous part of Speeqe, to be able to control who comes on my
chatrooms, so the problem isn't solved :-(

If you have any idea why I cannot use an existing account to log in a
chatroom, feel free to help me :D

Nathan Zorn

unread,
Mar 29, 2009, 5:43:51 PM3/29/09
to spe...@googlegroups.com
Oh, please subscribe to the speeqe mailing list.  I have to moderate each message and it helps to not have to moderate all of your messages. :)   spe...@googlegroups.com

Nathan Zorn

unread,
Mar 29, 2009, 5:47:49 PM3/29/09
to spe...@googlegroups.com
Speeqe usually has access to the username and password ,so if  you login from the website it works.  The login dialog also uses the website code to authenticate.  You usually only need to point speeqe at your database and it will work.   What database do you use to store username and password?


There is a way to use just javascript to authenticate, but that will require some editing of the templates.

Thomas Arnoux

unread,
Mar 29, 2009, 6:25:09 PM3/29/09
to spe...@googlegroups.com
On Sun, 2009-03-29 at 17:47 -0400, Nathan Zorn wrote:
> Speeqe usually has access to the username and password ,so if you
> login from the website it works. The login dialog also uses the
> website code to authenticate. You usually only need to point speeqe
> at your database and it will work. What database do you use to store
> username and password?

I have an sqlite database for the django part of Speeqe, but I don't
know what it is used for (configured in the local_setting.py file in
speeqeweb's directory). Which database should Speeqe use to have access
to passwords or usernames? Since I am trying to log in to my own
account, there is no reason for Speeqe to know the password, or to keep
it in its database, is there?

> There is a way to use just javascript to authenticate, but that will
> require some editing of the templates.

I'd rather use the django part too, to get full features.

--
vetetix

chad selph

unread,
Mar 29, 2009, 9:38:23 PM3/29/09
to spe...@googlegroups.com
Can you browse to your domain/xmpp-httpbind ?
I've decided this is my problem. Since I'd prefer to use only
apache/ejabberd, is it possible to set up a
<Location> that proxy's domain/xmpp-httpbind to domain:5280 (where
ejabberd is running http_bosh)? Or is it possible to code this part
inside django? That would be nice too to minimize the amount of
coupling with other projects.

chad selph

unread,
Mar 29, 2009, 11:02:41 PM3/29/09
to spe...@googlegroups.com
I've managed to get apache to proxy; and as far as I know it's
correct. I just did:

ProxyPass /xmpp-httpbind/ http://localhost:5280/http-bind/

and I can browse to mydomain/xmpp-httpbind/ correctly. But I still
have the same problem, joining a chat room results in:

disconnected authentication failed connection failed connected
Joining Room.....
authenticating..

written in green and red on the left side. If I log in from the
"change user" with a random user name and no password (to prove I have
anonymous auth) then all I get is:

Joining Room.....

Nathan Zorn

unread,
Mar 30, 2009, 2:06:03 PM3/30/09
to spe...@googlegroups.com
If you have speeqe setup to use sqlite, it should be fine.  The punjab python script is used by speeqe to authenticate.  If that is working, you should be able to login through the website without any problems.  I sent the instructions on how to use this script from the command line.  do you need more?
Reply all
Reply to author
Forward
0 new messages