You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@spamassassin.apache.org by John Madden <ma...@skynet.ie> on 2005/02/23 14:05:45 UTC

[PATCH] Config file for spamc

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hey,

We (UL Computer Society -- www.skynet.ie) recently came up against a
problem. We were running spamd on our primary server (primary == mail,
mail filtering and nfs for /home) but the load being caused by spamd was
killing the nfs access from other machines on the network. We decided to
move spamd off that server to another one in the network.

All went well, except that spamc doesn't have a way to globally change
user options. We wanted to make the switch with no visible change to the
users, and it would've taken far too long for users to change their
.procmailrc files to add the -d hostname option. Initially, I changed
transport_init() in libspamc.c to use TRANSPORT_TCP and the server we
wanted, but since we install spamassassin from CPAN, this is likely to
get overwritten in future.

So, I put together this patch. It causes spamc to read
/etc/mail/spamassassin/spamc.conf (if it exists) and parses the hostname
to use from there. Currently, all it parses it the hostname, but I
figured it might be useful if other options need to be set globally.

Patch (spamc.patch) is attached, and is also available on
http://maddenj.skynet.ie/useful/patches/spamc.patch

- -- 
Chat ya later,

John.
- --
BOFH excuse #1: clock speed
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)

iD8DBQFCHH+oQBw+ZtKOvTIRAtIaAJ4rCeRxnkZ5zQW2IH9RerJvv9llXwCeMu+o
DyIVjm9MNrUB9k0shw70k2A=
=dU/j
-----END PGP SIGNATURE-----

Re: [PATCH] Config file for spamc

Posted by Sidney Markowitz <si...@sidney.com>.
John Madden wrote:
> So, I put together this patch. It causes spamc to read
> /etc/mail/spamassassin/spamc.conf (if it exists)

John,

Would you open a ticket for this on Bugzilla at
http://bugzilla.spamassassin.org as an RFE (severity: enhancement) and
attach your patch there using the Create a New Attachment button?

That will keep it from getting lost or overlooked.

I don't think the patch is complete, as it is more *nix specific than
spamc itself is. There needs to be something to specify a different
configuration file for Windows, VMS, etc., either by compile-time
conditionalization or a preprocessor variable that can be set in the
makefile used on different platforms.

That said, if you post what you have in Bugzilla, anyone who wants to
finish it can work on it, and anyone who wants to use it as is on their
own site will be able to find it when they search the bug list for this
problem.

Thanks,

 -- Sidney Markowitz
    http://www.sidney.com/