[Dovecot] sieve plugin

Андрей dukenukem at vpcit.ru
Tue Sep 2 09:13:13 EEST 2008


I try to cinfigure dovecot run sieve scripts on incoming mail.

In my dovecot.conf:

	<...>
	protocol lda {
	# Address to use when sending rejection mails.
		postmaster_address = root at vpcit.ru
	
	# Hostname to use in various parts of sent mails, eg. in Message-Id.
	# Default is the system's real hostname.
		hostname = vpcit.ru
	
	# Support for dynamically loadable plugins. mail_plugins is a space separated
	# list of plugins to load.
	#mail_plugins =
		mail_plugin_dir = /usr/lib/dovecot/modules/lda
	
	# Binary to use for sending mails.
	#sendmail_path = /usr/lib/sendmail
	
	# UNIX socket path to master authentication server to find users.
		auth_socket_path = /var/run/dovecot/auth-master
	
	# Enabling Sieve plugin for server-side mail filtering
	mail_plugins = cmusieve
	}
	
	<...>
	
	plugin {
		sieve = /var/mail/%d/%1n/%n/.dovecot.sieve
	}

Then i set experiments on my maildir.
In /var/mail/vpcit.ru/d/dukenukem i created script .dovecot.sieve:

	require "fileinto";
	if header :comparator "i;ascii-casemap" :contains "Subject" "sieve check"
	{
		fileinto "Trash";
		stop;
	}

Permissions on /var/mail/vpcit.ru/d/dukenukem are:
	drwx------  5000 mail

So script should put every message that has "sieve check" subject into Trash 
folder.

1) Trash folder isn't created, should i create it manually?
2) Even when i create Trash folder and make 777 permissions to maildir, 
nothing happens (message is dropped into inbox dir)
3) Should i configure my Kontact (KMail) e-mail client some way?
4) What i've done incorrect?

The mail system works fine at the moment for receive and send, trouble only 
with sieve scripting.

Yours faithfully,
Andrey.


More information about the dovecot mailing list