grabs the username to pass to spamc from the RCPTTO: note that broken spammers do things like RCPTTO: [EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED] and this will be parsed incorrectly..
Has only been tested with user-prefs stored in mysql database (but other ways "should" work ;) ).
In addition to checking for RELAYCLIENT to see if message should be scanned, now also checks QMAILLOCALUSER. This is to prevent outgoing mail sent via the shell from being scanned. QMAILLOCALUSER should be set in the /etc/profile or in a script in /etc/profile.d
This patch has only been tested on a couple servers and no warranty is expressed or implied.
Questions/comments should be forwarded to "wwong at blackstar.net"
Patch to qmail-scanner-1.15 and run ./configure .. it "should work"
New options to ./configure:
--vpop-domains "one.domain,two.domain" Defaults to nothing
Comma-separated list (no spaces!)
of domains that are vpopmail domains.
this controls the behavior of SpamAssassin's
user prefs any mail checked for a vpopmail
domain SA will be passed -u "[EMAIL PROTECTED]"
all other domains SA will only be passed
-u "user".
To do alias mappings see the example qmail-scanner-aliases file that is
included, create a /var/qmail/users/qmail-scanner-aliases file to suit your own needs, make sure it is chown qmailq and chmod 0600, this is because there is basically almost no sanity checks on this file ;) and potentially using this file you can pass spamc extra arguments.. maybe.. could be a security hazard.
What is really needed is a suid program that does the sanity checking and adds and removes line in this file. If you look at the example qmail-scanner-aliases file you will see why the sanity checking should be in another program.. too much over head ;)
qmail-scanner-1.15-vpop-alias-userpref.patch.gz
Description: Binary data