[Dovecot] [dovecot]

pod pod at herald.ox.ac.uk
Wed Mar 10 20:35:40 EET 2010


"Rick Romero" <rick at havokmon.com> writes:

> Yeah.. procmail filter to modify the subject would satisfy me.
>
> I'm by no means a procmail expert, but this seems to work (though
> [Dovecot] gets put before the Re:)
>
> :0 fhw
> * ^List-Id:.*Dovecot Mailing List
> {
>   :0 fhw
>   * ^Subject:\/.*
>   | formail -I "Subject: [dovecot] $MATCH"
> }

I realise this is a late response on this thread and is probably overly
pedantic but RFC 2919 (List-Id) is clear about which bit of the List-ID:
header is actually the list-id.  It's the bit in angle brackets:

   The List-Id header MAY optionally include a description by including
   it as a "phrase" [DRUMS] before the angle-bracketed list identifier.
   [...]
   For many MUAs the parsing of the List-Id header will simply consist of
   extracting the list identifier from between the delimiting angle
   brackets.

   The syntax of the List-Id header follows:

   list-id-header = "List-ID:" [phrase] "<" list-id ">" CRLF

So if you are going to do List-ID filtering I suggest doing it on the bit
in angle brackets not the phrase part as has been done in the procmail
recipe above.  Thus in procmail:

:0 fhw
* ^List-Id:.*<dovecot\.dovecot\.org>
[...]

and in sieve:

if header :contains "list-id" "<dovecot.dovecot.org>" {
[...]


More information about the dovecot mailing list