• 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 Secure email reception from MX

Erwan

Regular Pleskian
Hi all,

On a server (Plesk Obsidian 18) we have domain mail (Postfix / Dovecot). The MX domain names are hosted on another server (anti-spam system) which sends the flow of messages to our server.
Except that some spam still arrives on our server because the messages are sent directly to the IP of this server (old MX).

How is it possible with Plesk or iptables instruction to only allow the reception of message from the flows coming from the ip of the MX?

Thank you.
 
You cannot use iptables for this, because then you will also block outgoing mail operations. You can of course block all incoming packets from different servers on port 25 except packets coming from your one anti-spam-solution, but when a mail goes out, the server needs to be able to talk with the recipient server, which won't work properly if you block port 25 for incoming packets. There might be a solution where you leave a port open for a certain amount of time when your server initiates the first packet to a destination, but it's still a very questionable setup.

I think the only way to achieve what you want is to manually edit the Postfix configuration. Here might be a good place to start on your case (last post in the thread by Viktor Dukhovni:
The problem with an edit is that Plesk might overwrite changes of the Postfix configuration when you do parameter changes in Plesk.
This here could also help:
 
Back
Top