Advanced SpamAssassin Settings
Matt Kettler
mkettler at EVI-INC.COM
Wed Dec 3 21:40:31 GMT 2003
At 04:25 PM 12/3/2003, Stephen Swaney wrote:
>All SpamAssassin settings can (and should) be placed in:
> <path_to_MailScanner_conf_files>/spam.assassin.prefs.conf
>
>This will save your settings when next you upgrade SpamAssassin.
>The other files can be empty or non-existent.
True, but this has nothing to do with the poster's actual question.
spam.assassin.prefs.conf is used to replace the "user_prefs" file in
SpamAssassin. None of this will stop spamassassin from automatically
reading the "site rules" as well, even when called via MailScanner.
ie:
/usr/local/etc/spamassassin/*.cf
(although duplicate options in spam.assassin.prefs.conf will take priority,
the other files will still be read.)
And the original poster's question regards how to prevent SA from reading
files in /usr/local. The *only* way to do that is to hack the SpamAssassin
source code.. the list of paths used for this search are hard coded into
spamassassin.
Also, as an added detail, SA will only handle the *first* site-rules dir it
finds.. it will not try any others..
The raw SA source code for 2.60 has this path search in SpamAssassin.pm:
# first 3 are BSDish, latter 2 Linuxish
@site_rules_path = (
'__local_rules_dir__',
'__prefix__/etc/mail/spamassassin',
'__prefix__/etc/spamassassin',
'/usr/local/etc/spamassassin',
'/usr/pkg/etc/spamassassin',
'/usr/etc/spamassassin',
'/etc/mail/spamassassin',
'/etc/spamassassin',
);
Note that __local_rules_dir__ and __prefix__ are filled in with information
determined when you compile/install SA.
More information about the MailScanner
mailing list