I've researched for an answer to this question and can't find anything.
I have Postfix running on Debian Stretch. I will soon be setting up Rspamd.
Here's the logic of what I want to have happen when spam arrives:
- Postfix receives a message from the contact form on my website (via PHPMailer)
- Postfix sends the message to Rspamd for processing
- Rspamd flags the message as spam and adds appropriate headers
- Postfix does NOT send the message to [email protected], but rather [email protected]
From what I gather, it seems that milters do not have this ability. How can this be accomplished?
Postfix can check the headers set by the milter with
milter_header_check
. The postfix documentation also provides an example:Just replace the
FILTER
action withREDIRECT [email protected]
and it should work.Cf. http://www.postfix.org/header_checks.5.html