[Dovecot] duplicates with multiple To/CC and sieve redirect copy

Timo Sirainen tss at iki.fi
Wed Feb 22 01:09:35 EET 2012


On 22.2.2012, at 1.02, Adam Szpakowski wrote:

> On 21.02.2012 23:57, Timo Sirainen wrote:
>> On 22.2.2012, at 0.46, Adam Szpakowski wrote:
>>> In one installation we are using sieve "redirect :copy" to create copy of the incoming email (local boss gets copy of its employees mails).
>>> There is a problem when the incoming email has multiple To/CC entries with local users. Multiple copy/redirects are created (one for each employee) and there are multiple copies in "boss" account.
>> Could this instead be implemented by MTA as automatic bcc: boss of all incoming mails?
> Unfortunately no. The employee/boss structure is quite complicated. Some employees have multiple "bosses", there are also some "project" emails when the structure is even more complicated.
> We are using dedicated sieve_before script for each user based on %u variable.

Well, it would be possible to build a doveadm script that deletes the duplicates after delivery, but currently there's no implementation to avoid delivering duplicate Message-IDs in the first place.

I don't really like such a Message-ID-based deduplication feature enabled by default, but something like this could be nice:

fileinto :copy :x-deduplicate "boss";

Anyway, probably not going to be implemented anytime soon.




More information about the dovecot mailing list