OPNSense with Postfix Plugin as smarthost/relay for internal networks ?

Started by BeNe, March 08, 2018, 10:00:44 PM

Previous topic - Next topic
Hello OPNsense Users,

is there a way that i can use the OPNSense as Smarthost or Relay for my internal network devices ?
I don“t want to add my external Mails Credentials (User/Password) to all my NAS, Printer, Switches and 3rd Party Software for Notification Mails. Have no more an internal Mailserver since there is Google Apps or Office 365 with Exchange in the Cloud.

All devices should send their mails to the OPNsence and the OPNSense via smarthost outside. The external Mail Credentials are only one time in the firewall for the smarthost needed. Restriction would possible with a Firewall rule. Also all Mails could checked for Spam before they leave the network.

Is there such an option ? Could not find it inside the Postfix Plugin.




If it help to speed development here you can find few packages for another fork, just need to be adapted for OPNsense:
https://github.com/marcelloc/Unofficial-pfSense-packages

There's no problem of adding this feature, quite easy setup. I have to first finish adding IPv6 to BGP in FRR Plugin and then I'll focus in this one :)

Can you please test and verify if it works for you? Then it can go to the next stable:


opnsense-patch -c plugins 9fd323e

Of course! It works just fine  8)
Thank you very much.

Small full help adjustment for the Smarthost text:
QuoteSet the IP address where all outgoung mail are sent to
-> Set the IP address or FQDN where all outgoung mail are sent to

I used the FQDN of my Mailserver because of the Certifiacte.

Good catch, done! So perhaps this will find it's way to 18.1.5 if it's not too late ...

It'll be in 18.1.5, but that's next week now for other reasons. :)

Thanks to you both!

Cheers,
Franco

Is there any way to specify the outgoing port. I'm trying to get Gmail to work as a smartrelay using port 587 or 465 because my ISP blocks outgoing port 25 since I'm using this at home. I've tried [smtp.gmail.com]:587 and smtp.gmail.com:587 but neither have worked. Any advice or will this need modified to get this working?