I have a problem with spam and postfix + postgray. Generally it works fine, but I have these problems:
- false-positives.
- good emails get rejected.
Can I configure postfix (and postgray) so that when an email is rejected, then redirect to [email protected] (change recipients).
Or maybe copy each emailand send it to [email protected], and then apply filtering? If hit restriction than just reject (another copy is in [email protected]).
How to do it?
You can't do it. You can either REJECT (or DEFER) the mail or ACCEPT (or REDIRECT) the mail. If you REJECT the mail, then the mail doesn't even arrive at your server as it is canceled right away during connection attempt. When you ACCEPT the mail then you can analyze the mail content but then it is impossible to REJECT the mail afterwards. So you can only have the one or the other. But not both.