I have installed ejabberd on a new installation of Ubuntu 16.04 on digitalocean cloud and am able to connect to it from pidgin from my local machine without configuring any firewall rules.

Curious to see the ports open I did

nmap <ip_address>

22/tcp   open  ssh
5222/tcp open  xmpp-client
5269/tcp open  xmpp-server
5280/tcp open  xmpp-bosh

However, my ufw status is inactive and

 sudo iptables -S


is empty

As suggested here I listed each of the tables contents using

sudo iptables -vL -t <table_name>

for each of filter, nat, mangle, raw, security all showing empty outputs.

I would like to know if there is some other way in which firewall rules are configured and displayed.

  • @dsstorefile1 Can ports be opened independent of any firewall like ufw or iptables? All results in google show either using some firewall like ufw or iptables to open ports in ubuntu – Kalyan Raghu May 20 '18 at 11:34

Your misunderstanding is this: If there is no configuration for Netfilter (iptables) then everything is allowed. The default policy for all chains is ACCEPT.

| improve this answer | |

Is your firewall enabled?

Chances are that you have your rules set, but just haven't turned your firewall on.

| improve this answer | |
  • ufw is not enabled. However, ports are open and I can connect to ejabberd from xmpp clients from another computer. I would like to know why iptables -S output is empty when rules are set? – Kalyan Raghu May 20 '18 at 15:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.