Sieve: deleteheader now working with duplicate filter for implicit keep
Alec Moskvin
alecm at gmx.com
Sat Aug 29 22:04:18 EEST 2020
Hello,
I have a rule to always delete a header. If the message gets fileinto'd,
the header is gone, but if it's delivered into the INBOX through
implicit keep, the header does not get deleted.
Interestingly, if I remove the "if duplicate" filter, the header does
get deleted as expected.
I'm using the latest Dovecot 2.3.11.3 / Pigeonhole 0.5.11.
Any idea why this is happening?
Thanks,
Alec
=== Sieve filter
require ["fileinto", "editheader", "duplicate", "mailbox"];
deleteheader "X-Bad-Header";
if duplicate {
fileinto :create "Trash";
stop;
}
if header :matches "subject" "*filter*" {
fileinto :create "Filtered";
}
=== Example (note ${RANDOM} to bypass duplicate filter)
$ /usr/libexec/dovecot/deliver << -end-
To: me at example.com
From: someone at example.com
Subject: Test Message
Message-Id: <${RANDOM}@example.net>
Date: Thu, 20 Aug 2020 00:21:24 +0000 (UTC)
X-Bad-Header: DELETE ME
Hello world
-end-
More information about the dovecot
mailing list