Apple 10.6 Server User Manual


 
Chapter 2 Mail Service Setup 39
Server-Side Mail Rules
Mac OS X Server supports Sieve scripts to process server-side mail rules. Sieve is an
Internet standard mail ltering language for server-side ltering. Sieve scripts interact
with incoming mail before nal delivery.
Sieve acts much like rules in mail programs to sort or process mail based on user-
dened criteria. Sieve can provide such functions as vacation notications, message
sorting, and mail forwarding.
Sieve scripts are kept for each user on the mail server at /var/spool/imap/dovecot/
sieve-scripts/GUID. The directory is owned by Mail service, so users normally don’t have
access to it and can’t put their scripts there for mail processing. For security purposes,
users and administrators upload their scripts to a Sieve process, managesieve, which
transports the scripts to the mail process for use.
To enable Sieve support:
For Sieve to function, you must enable its communications port.
By default, Sieve has the vacation extension.
Place scripts in the central script repository at /usr/sieve/.
Do not use Sieve scripts to process mail for mail aliases set up in Workgroup Manager.
You must use Postx-style aliases. See “Creating Additional Mail Addresses for Users
on page 77.
1 In Server Admin, select a computer in the Servers list, then select Mail.
2 Click Settings.
3 Select the Filters tab.
4 Select Enable server side mail rules.
From the command line:
Add the following entry in /etc/services/:
...
sieve 2003/udp # Sieve mail filtering
Sieve 2003/tcp # Sieve mail filtering
...
Sieve’s complete syntax, commands, and arguments are found in IETF RFC 3028 at
www.ietf.org/rfc/rfc3028.txt?number=3028.
Other information about Sieve and a sample script archive can be found in
Appendix B, “Sample Sieve Scripts” and atwww.cyrusoft.com/sieve.
For more information about managesieve, see http://wiki.dovecot.org/ManageSieve.