I'm using Postifx version 2.5.5 with a pipe to DBMail. In DBMail version
2.2.7 I have a mailbox with multiple aliasses. For example mailbox
[EMAIL PROTECTED] with aliasses [EMAIL PROTECTED] and [EMAIL PROTECTED] which
will deliver all of their mail to [EMAIL PROTECTED] I would like to have the
mail for john delivered to a John-directory and the mail for peter delivered
to a Peter-directory, both directories within the [EMAIL PROTECTED]
To achieve this, I am using the Sieve script below:
require "fileinto";
if address :contains :all ["to", "cc", "bcc"] "[EMAIL PROTECTED]" { fileinto
"John"; }
if address :contains :all ["to", "cc", "bcc"] "[EMAIL PROTECTED]" { fileinto
"Peter"; }
If a mail with a single recipient is received, this works perfectly. But
when I send a mail with both [EMAIL PROTECTED] and [EMAIL PROTECTED] as
recipient, the mail will be deliverd twice to both directories, so four
mails in total.
What is the best way to solve this? Is there a way to check in the Sieve
script what the initial recipient is of the mail that is currently handled?
Do I have to used something else than a Sieve script? Any help is
appreciated!
--
View this message in context:
http://www.nabble.com/Filtering-mail-with-multiple-recipients-tp19630701p19630701.html
Sent from the dbmail users mailing list archive at Nabble.com.
_______________________________________________
DBmail mailing list
[email protected]
https://mailman.fastxs.nl/mailman/listinfo/dbmail