The list is loaded, when the configuration file contains section [list_timsieved_scripts].
For a domain, user, and script name, this list determines the location on the file system, where the Sieve script is located.
The only option in the section is
imapd.conf. If present, it specifies from which file to load the default Cyrus Imap configuration. When absent, the usual Cyrus Imap mechanisms are used to find the configuration file.
list_timsieved_scripts reads from
imapd.conf the variables
fulldirhash. How the paths are calculated is best seen by looking at the source code. As a rule of thumb, if timsieved uploads a sieve script for a user and timsieved and aegee-milter share the same imapd.conf file, then aegee-milter will find the file uploaded by aegee-milter.
list_timsieved_scripts looks for scripts per recipient based on the RCPT TO: parameter.
For addresses without domain, the
In a mail system there are different forms of equivalence between two addresses. The MTA has an alias system, and virtual domains, that are used to determine if two addresses deliver emails to the same destination. The authentication system can consider also two distinct user names as equivalent.
aegee-milter knows nothing about the aliasas in the MTA or the authentication system. If two domains are supposed to be handled as equivalent by aegee-milter, then either there must be hard or symbolic links on the file system, so that aegee-milter can find the right file on the file system. Likewise, if a person has two addresses and the same Sieve filtering rules shall be applied to emails to any of the addresses, the file system must have on the right, distinct place the Sieve scripts for both addresses. Think of two uploads over timsieved for the one and for the other address.
Besides personal scripts, there are also global scripts per domain. If a global script is searched for a particular domain and is missing, the global scripts of the default domain are not retried.
A final hack: in terms of ManageSieve there is a default script per user. timsieved can be used change the default (active) script. These scripts can be executed by two different systems: by aegee-milter at SMTP time, which has the capability to reject messages at SMTP level, but cannot call
fileinto, and by Cyrus Imap as MDA which cannot perform reject at SMTP level, but can do
fileinto. To permit of both systems to coexists, when list_timsieved_scripts loads the default script for a recipient, it first check if a file
default.siv.bc exists. That is, if for the user over ManageSieve a file called
default.siv was uploaded. If this file exists, then aegee-milter uses it in place of the default script. Otherwise list_timsieved_milter delivers the name of the default (active) Sieve script.