Zimbra is the mail server of many organisations that run their own mail, and it ships with built-in anti-spam and anti-virus components. On their own, these struggle against current phishing, business email compromise and QR-code attacks, and the server itself is a frequent target.
Limits of the built-in filter
- Rule and signature updates depend on whoever runs the server.
- Newer layers such as click-time link checks, QR-code reading and executive impersonation (BEC) detection are missing.
- Filtering runs on the server itself: a malicious message reaches your server first and is judged there.
- There is no portal where users manage their own quarantine; every false positive lands on IT.
The server is a target too
Zimbra servers face the Internet directly and are attacked often. CVE-2024-45519, published in 2024, allowed commands hidden inside email addresses to run code on the server. Updating promptly is essential; a gateway in front adds a layer by refusing such addresses before they reach the server.
Put a gateway in front of Zimbra
The strongest setup sends incoming mail through a cloud security gateway first: your domain's MX record points to the gateway, the gateway inspects the mail and delivers clean mail to your Zimbra server. Mailboxes stay on Zimbra; nothing is migrated.
- Add your domain at the gateway and prove ownership with a TXT record.
- Enter your Zimbra server's public IP address or host name and SMTP port as the delivery target.
- Confirm with a test message that Zimbra accepts mail from the gateway.
- Point the MX record to the gateway.
- Open port 25 on your server to the gateway's addresses only, so attackers cannot skip the MX and deliver straight to your server.
Avoid double filtering
If Zimbra keeps its own spam scoring behind a gateway, surprises follow. When the gateway adds a warning banner or rewrites links into protected links, the original sender's DKIM signature naturally breaks. A Zimbra server that checks that signature again can send a legitimate message to junk for a DMARC failure. We saw this at a customer.
So do not re-run authentication and spam scoring on Zimbra behind the gateway: switch Zimbra's anti-spam and anti-virus services off, or at least zero its DMARC and DKIM based scores. This is safe only while port 25 accepts the gateway alone.
su - zimbra
zmprov ms $(zmhostname) -zimbraServiceEnabled antispam -zimbraServiceEnabled antivirus
zmcontrol restartRun the commands in a maintenance window and note the current settings first.
SecuraWall with Zimbra
- Multi-layer inspection: spam and phishing, malicious attachments, links, QR codes and images, BEC and impersonation.
- Command syntax hidden in email addresses (CVE-2024-45519 style) is refused before it reaches your server.
- Quarantine users come from the Zimbra API; staff manage their own quarantine in 8 languages.
- Delivery by IP address or host name and port; mail waits in the queue while your server is down.
- Optional SMTP Relay for the same server's outgoing mail.
Frequently asked questions
Do I have to migrate Zimbra mailboxes?
No. The gateway changes only the route of the mail; mailboxes, users and webmail stay on Zimbra.
Is it safe to switch off Zimbra's anti-spam service?
Only when all incoming mail passes the gateway and port 25 is open to the gateway alone. Otherwise mail delivered directly stays unfiltered.
Is it the same for Zimbra 8.8 and 10?
The gateway setup is the same for both. Service and administration commands can differ slightly between versions; check the documentation of your version.