f.haeder.net

Problem with http-bind to XMPP server

I have xmpp-based chat enabled on this site where I currently have some trouble with. You can reach it here: https://f.haeder.net/http-bind

The upstream server behind it runs at 127.0.0.1:5280 and is configured as followed:
ejabberd.cfg
{5280, ejabberd_http, [captcha, http_put, http_poll, http_bind]}
and ...
ejabberd.yml
port: 5280
ip: "127.0.0.1"
module: ejabberd_http
request_handlers:
"/websocket": ejabberd_http_ws
## "/pub/archive": mod_http_fileserver
web_admin: true
http_bind: true
## register: true
captcha: true
tls: true
certfile: "/etc/ejabberd/ejabberd.pem"


In /var/log/ejabberd/error.log I see tons of these messages:
2018-05-13 xx:xx:xx.xxx [critical]<0.2508.0>@extauth:loop:142 extauth script has exitted abruptly with reason 'normal'
chat ejabberd friendica xmpp
Process is clearly listening:
# netstat -lnp |grep 5280
tcp 0 0 127.0.0.1:5280 0.0.0.0:* LISTEN xxx/beam.smp
#
In my #apache2.4 configuration file I have this:

<IfModule mod_proxy.c>
<IfModule mod_proxy_http.c>
ProxyPass /http-bind http://127.0.0.1:5280/http-bind retry=0
</IfModule>
</IfModule>
Ah, if I call that URL with lynx, nothing returns, but with https something returns! Here is the bug!
FIXED!!! I had to set tls: false, restart ejabberd, then apache. #fixed
#TIL If you restart apache first, it won't work as ejabberd must be listening already when apache builds the proxy chain (which makes sense again). And yeah, having TLS on 127.0.0.1 makes no sense. ;-)

Well, #shit-happens
Later posts Earlier posts