[Dovecot] sieve_after scripts with virtual domains

Ciro Scognamiglio c.scognamiglio at cslash.net
Sat Aug 21 15:08:14 EEST 2010


Hi all,
first of all I am new to the list, so hello everyone :)

I recently encountered an annoying problem with sieve, I am using dovecot version 1.2.13 on centos 5.5, the packages installed are the following:
dovecot-sieve-0.1.17-5.el5
dovecot-managesieve-0.11.11-0_4.el5
dovecot-1.2.13-1_111.el5

the mail server is configured with virtual hosts (mysql), also the sieve plugin and managesieve are active. Users can create their own filters through roundcube and everything works fine.
I also put two script to be executed before all sieve scripts in sieve_before, they just move any SPAM or VIRUS tagged message to a Junk folder. The problem is that while this works for my domain (that is also the server domain) it doesn't for the others domains, it seems the sieve_before scripts get ignored.

I made many tests with the domains I am hosting, if I send a spam message (I am using the spamassassin test messages) it gets marked as SPAM, but gets only moved to the junk folder if the recipient is @cslash.net (that is my domain).

here is some config extracts:

=== dovecot.conf ===
plugin {
  sieve = ~/.dovecot.sieve
  sieve_dir = ~/sieve
  sieve_before = /srv/mail/sieve-before
  sieve_after = /srv/mail/sieve-after
}
=======

/srv/mail $ cat sieve-before/spam.sieve 
require "fileinto";
if header :contains "X-Spam-Flag" "YES" {
  fileinto "Junk";
}

P.S.
The sieve scripts are all compiled.



More information about the dovecot mailing list