• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Question Port 25 is blocked despite an explicit firewall rule

msinne

New Pleskian
Hello,

I'm using the msmtp relay addon/plugin for my php scripts to send mails (eg contact forms etc.)
Postfix and sendmail are deactivated.
I set up the external relay gateway correctly. The relay gateway sends through port 25.
I tried my scripts - no mail is going out.
I checked the ports with nmap. Port 25 is blocked.
I then put a firewall (the default plesk firewall) rule that opens tcp port 25, then
checked again with nmap, but port 25 is still blocked locally.
Where's the trick? Am I missing something or getting something wrong?

Best regards
Michael
 
no I checked the port locally on the machine with nmap and it's closed.
I asked my ISP already and he said port 25 is not blocked.
 
I asked my ISP already and he said port 25 is not blocked.

By ISP (internet service provider) you mean the company providing you with an internet connection at the place you reside/work? Because you ought to ask your hosting/cloud provider if port 25 is open.
 
O.k., I think what you are seeing is kind of an illusion. I think that everything is actually correctly set-up, but you are trying to connect to port 25 on your local system. However, there is no mail server on port 25 (or other ports) on your local server. When you use the MSMTP option, you do not have any local mail server or mail functions, so you have to make sure that any script where you send mails from is directly connecting to your external mail server. From what I understand you cannot combine the MSMTP option with a local mail functionality to submit mails on your server.
 
Back
Top