Topic: Check for spam before forwarding.
==== Required information ====
- iRedMail version: 0.8.5
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Linux/BSD distribution name and version: CentOS 6.4 64bit
- Related log if you're reporting an issue:
We host on our iRedMail server some domain which forward emails (though aliases) to another mail server (Exchange) in our lan. The IP address of iRedMail server is whitelisted for spam on the second server.
The problem is:
Mail alias email@example.com on iRedMail server is configured to forward all emails to firstname.lastname@example.org on another server which don't check for spam SMTP traffic incoming from iRedMail server.
A spam email (like GTUBE) sent to email@example.com is immediately forwarded to firstname.lastname@example.org without be analyzed so a lot of spam is delivered to email@example.com
How can I tune iRedMail to scan for spam all inbound messages before forwarding (or delivering) it?
I've tried to add "#receive_override_options = no_address_mappings" to main.cf and I got an NDR because the destination address is an alias no more translated and doesn't have a mailbox on iRedMail server for delivery.
So I've modified as follow "# -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks" the line "127.0.0.1:10025 inet n - - - - smtpd" in master.cf and now I get two emails: The first one forwarded to firstname.lastname@example.org with the "spam" mark in the subject and a copy also stored in iRedAdmin control panel (iredadmin/activities/quarantined) which cannot be released or, better, when it is released it is not delivered with this error in maillog:
Aug 19 18:58:20 postfix amavis: (rel-Qi8n9OV1WsIi) Quarantine release Qi8n9OV1WsIi: missing X-Envelope-From or Return-Path
----Urgent issue? Pay iRedMail developer to solve it remotely at $29.