[Dovecot] Plugin mail-filter tangles

Steffen Kaiser skdovecot at smail.inf.fh-brs.de
Thu Jun 5 14:13:49 UTC 2014

Hash: SHA1

On Thu, 5 Jun 2014, Stanislas SABATIER wrote:

Hallo Stanislas,

> Le 05/06/2014 14:06, Steffen Kaiser a écrit :
>> If your observation are true, you cannot. I sligthly remember a
>> discussion about a plugin, that changes the message content. Timo
>> answered that with "that is not supported". Also, see:
>> http://wiki2.dovecot.org/Plugins/MailFilter
>> "(TODO: Modifying the mail during writing would be possible with some
>> code changes.) " in first paragraph.
>> Encrypting the message is "to modify the mail" IMHO.
> I do encrypt/decrypt email on-the-fly for months now with the help of
> mail-filter plugin.
> It works perfectly as long as the decrypted email is exactly as it was
> before it was encrypted, which is the case with my bespoke
> encrypt/decrypt programs.
> That is not the point I raised in this thread. The point is that, in a
> specific circumstance, Dovecot is trying to read an email that has been
> encrypted without having the user this email belongs to authenticated.

Yes, I understand and I've read the thread including your reply from Sat, 
31 May 2014 16:24:22. Possibly, this situation is the only one or just one 
of the problems, why Timo wrote that TODO in the Wiki.

What you've wrote seems to indicate that Dovecot passes the only existing 
copy of the message through the filter and drops it to user2's mailbox. In 
order to drop it to user3, Dovecot needs a copy of the message again. This 
is what the "-p" option of Dovecot deliver does.

Dovecot would need to spool the incoming message somewhere before passing 
through the filter for each recipient. Or fork as many delivery processes 
as recipients there are and multiplex the incoming message to all forks.

- -- 
Steffen Kaiser
Version: GnuPG v1.4.11 (GNU/Linux)


More information about the dovecot mailing list