Amavis - spam related headers
From amavisd-new docs: (http://www.ijs.si/software/amavisd/amavisd-new-docs.html#tagkill) "if spam score is at or above tag2 level, spam-related header fields (X-Spam-Status, X-Spam-Level, X-Spam-Flag and X-Spam-Report) are inserted for local recipients"
The headers are needed if using the "Move Spam Emails to Junk directory" mail filter on a mailbox as maildrop will check for the existence of the 'X-Spam-Flag' header. But in cases where there are aliases and catchall instructions attached to these mailboxes the aliased address is not found in spamfilter_users and amavis, thinking it's not a local recipient, does not insert the header even in cases where the score was in tag2.
A workaround to the problem is to set local_domains_acl = ( "." ) which is obviously not ideal. A more permanent solution would be to set local_domains_maps to the list of domains found in the dbispconfig database. Unfortunately at this time there is no way to set-up a sql map to build this list but by adding a routine to the mail_domain_insert, mail_domain_update and mail_domain_delete functions of the server component of ISPConfig an updated hash file can be generated (see: http://groups.google.com/group/mailing.unix.amavis-user/browse_thread/thread/ee54a400cc75327f/5387518955d2154a?pli=1) that could be used to map all local domains and ensuring that all locally destined messages get the required spam headers.