port configuration: is it possible to use port 25 untrusted for incoming and outgoing Mails?

inno-forum

Member
Oct 28, 2021
69
3
13
31
we understand that you can use a trusted port and an untrusted port on the mail gateway and for that you have to use different ports - do we need to use different ports for incoming and outgoing messages for the mail gateway to work properly, or can we also send and receive all mail traffic untrusted via port 25?
 
we understand that you can use a trusted port and an untrusted port on the mail gateway and for that you have to use different ports - do we need to use different ports for incoming and outgoing messages for the mail gateway to work properly, or can we also send and receive all mail traffic untrusted via port 25?
you need to have some way of distinguishing between internal and external - PMG uses ports for this - but you could also use different IPs for the two postfix servers to listen on - you'd need to adapt the master.cf.in template:
https://pmg.proxmox.com/pmg-docs/pmg-admin-guide.html#pmgconfig_template_engine

alternatively - if your internal mail only comes from a select network range (e.g. rfc 1918) you could also do port-translation with nftables/iptables

I hope this helps!
 
  • Like
Reactions: inno-forum