Open XMPP server to outside?


I’m dealing with a stubborn XMPP server via Openfire. I need to be able to open it so that certain people can connect to it from outside the firewall, but no matter what port forwarding rules I use, authentication always fails from the outside. Not only does the Spark program fail, Sparkweb says “not authorized”. I have port 5222 forwarded from the firewall directly to my openfire server. I’ve done port forwarding numerous times so I know that’s set up correctly.

There don’t appear to be any log files which show this failure.

I am on version 3.7.1 on CentOS 6. What should I try next?

What do you put as a server part in Spark? If you use server’s name, it should be resolvable on the Internet (DNS). Or you can try using IP address (external), or go to Spark’s Advanced settings on Login screen and put IP into host field and then put servername on the login screen into server part.

If you don’t have DNS running, you are going to face those problem consistently.


Well, it’s working here. I my case i’ve used Mikrotik to make the forwarding NAT rule, mapping incoming external trafic from the 5222 port to the internal ip of my openfire server. I’m using a script to update the dynamic dns ( so in the client (Spark running on Linux) I just used the ddns name and it connects very well. Tested on Android too (Xabber client) and everything went fine.

I’m running the openfire on Ubuntu Server 14.04.2 with Openfire 3.9.3. You can make a test: forward the 9090 port on your firewall and try to acess the openfire config panel. It’s a way to make sure your rules are working regardless the client used. You can try update your server version too…