LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (https://www.linuxquestions.org/questions/linux-security-4/)
-   -   firewalld port should be open but it isn't (https://www.linuxquestions.org/questions/linux-security-4/firewalld-port-should-be-open-but-it-isnt-4175651814/)

mjbradakis 04-09-2019 06:16 PM

firewalld port should be open but it isn't
 
So I run this command:

[root@fizzer etc]# firewall-cmd --list-services
dhcpv6-client mdns samba-client smtp ssh

smtp is a listed service, the port is listed as open:

[root@fizzer etc]# firewall-cmd --list-ports
1025-65535/udp 1025-65535/tcp 25/tcp 80/tcp 22/tcp 143/tcp 25/udp


iptables-save also shows port 25 is available, postfix is running, but the server is not accepting connections on port 25:


[root@fizzer etc]# telnet fizzer.bradakis.com 25
Trying 50.198.190.20...
telnet: connect to address 50.198.190.20: Connection refused

What is going on? Which programs are lying to me about port 25?

mjb.

ferrari 04-09-2019 06:53 PM

What is reported by the following command?
Code:

ss -tulpn | grep :25

ferrari 04-09-2019 07:05 PM

FWIW, here's the results I got from a port scan of that public IP address...

Code:

~> nmap 50.198.190.20
Starting Nmap 7.70 ( https://nmap.org ) at 2019-04-10 12:02 NZST
Nmap scan report for 50-198-190-20-static.hfc.comcastbusiness.net (50.198.190.20)
Host is up (0.19s latency).
Not shown: 846 closed ports, 152 filtered ports
PORT  STATE SERVICE
22/tcp open  ssh
80/tcp open  http

Nmap done: 1 IP address (1 host up) scanned in 17.37 seconds

Check that your ISP is not blocking that port as well.

mjbradakis 04-09-2019 07:27 PM

I feel like such a chump. I was a sys admin in the computer science department at the U of U for about a quarter of a century, seen a lot of variations of UNIX based systems, etc. etc.

The problem here was amazingly easy to fix. I spelled the hostname correctly in main.cf and it works now.

Sheesh!

mjb.

ferrari 04-09-2019 08:10 PM

At least it was just a simple typo in the postfix configuration. Thanks for the update.


All times are GMT -5. The time now is 02:24 AM.