Reputation: 18
I have a prosody server setup at example.com. I can connect to the bosh service using pidgin with the url http://example.com:5280/http-bind
and also on the broswer the same url replies :
It works! Now point your BOSH client to this URL to connect to Prosody.
For more information see Prosody: Setting up BOSH.
Now i am trying to with using the following command
new Strophe.Connection("http://example:5280/http-bind/").connect("[email protected]", "123456", callback);
where callback is a fuction(status)
I use to log the connection. The status at callback first is Strophe.CONNECTING and then Strophe.CONNFAIL .
I have enabled the debug log level on prosody and the /var/log/prosody/prosody.debug
doesn't add new entries (it works fine on pidgin).
Also, I have fixed the proxy by adding the following lines on apache2 virtualhost
<Location /http-bind>
Order allow,deny
Allow from all
</Location>
RewriteEngine On
RewriteRule ^/http-bind$ http://example.com:5280/http-bind [P,L]
I note that on pidgin I had to enable plain-text authentication in order to make it work and also I have the following setting on /etc/prosody/prosody.cfg.lua
(I have more but these seem related)
c2s_require_encryption = false
s2s_secure_auth = false
authentication = "internal_plain"
and also the following BOSH settings
consider_bosh_secure = true
cross_domain_bosh = true
At first, I thought that the problem was the encryption, however, since there are no log entries I am lost. Do you have any idea what the problem maybe, also do you think I should include any more info?
Upvotes: 0
Views: 1603
Reputation: 3316
"http://example:5280/http-bind/"
is not the same URL as "http://example.com:5280/http-bind"
. You should remove the trailing slash.
Upvotes: 1