Antispam MxGuard Smarthost General help New

Configuring Postfix to relay through MxGuard

daveA67 12 Nov 2025, 07:56

To send your Postfix server's outbound mail through the smarthost using authenticated submission, point its relayhost at MxGuard and give it the generated credentials.

In main.cf:

relayhost = [smtp.mxguard.uk]:587
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous
smtp_tls_security_level = encrypt

The square brackets stop Postfix doing an MX lookup on the smarthost name.

Create /etc/postfix/sasl_passwd:

[smtp.mxguard.uk]:587 your-generated-username:your-generated-password

Then run postmap /etc/postfix/sasl_passwd, secure the files, and reload Postfix.

Finally: add include:_spf.mxguard.uk to your SPF record so the relay's IPs are authorised for your domain. Send a test message and confirm it appears tagged outbound in your dashboard. If you're using IP-allowlist mode instead, drop the SASL lines and connect on port 25 from your registered static IP.

0 comments

Sign in with your TDesk account to comment.

← Back to all posts