0

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>

PORT     STATE SERVICE
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

-P INPUT ACCEPT
-P FORWARD ACCEPT
-P OUTPUT ACCEPT

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

2 Answers2

2

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

Hauke Laging
  • 90,279
0

Is your firewall enabled?

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

  • 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