I am a big fan of this patch:
http://qmail.org/qmail-smtpd-viruscan-1.3.patch
Since installing it, me and about 2000 others stopped getting MS viruses/worms. I am currently in the process of migrating a mail server over to new hardware and thought I would see what was new in the qmail arena. Then I found shupp.org and learned of netqmail and the qmail-toaster patch - nifty! After installing this patch:
http://shupp.org/patches/qmail-toaster-0.6.patch.bz2
I get this when trying to install the qmail-smtpd-viruscan-1.3.patch - any advice is appreciated since although I don't run Windows, a lot of people around here do and they will get on my case if all this mydoom nonsense starts creeping through - I don't know C (I program on PHP and Perl though) and don't really understand what happened in the error message below - please excuse my ignorance on this:
[EMAIL PROTECTED] netqmail-1.05]# patch < ../../tar/qmail-smtpd-viruscan-1.3.patch
patching file case_startb.c
patching file Makefile
Hunk #1 succeeded at 221 (offset 4 lines).
patching file qmail-smtpd.c
Hunk #1 FAILED at 96.
Hunk #2 succeeded at 191 with fuzz 2 (offset 72 lines).
Hunk #3 succeeded at 261 (offset 48 lines).
Hunk #4 succeeded at 408 (offset 109 lines).
Hunk #5 succeeded at 578 (offset 48 lines).
Hunk #6 succeeded at 661 (offset 109 lines).
1 out of 6 hunks FAILED -- saving rejects to file qmail-smtpd.c.rej
[EMAIL PROTECTED] netqmail-1.05]# cat qmail-smtpd.c.rej
***************
*** 96,101 ****
int bmfok = 0;
stralloc bmf = {0};
struct constmap mapbmf;
void setup() { --- 96,103 ---- int bmfok = 0; stralloc bmf = {0}; struct constmap mapbmf; + int sigsok = 0; + stralloc sigs = {0};
void setup() {
If I had to guess - something went wrong in the "setup" some sort of C function that doesn't return a value? From the looks of it, this "function" was heavily modifed by the qmail-toaster patch (bunch of tarpit, TLS, mfcheck in there) and that is why it didn't get patched correctly?
void setup() { char *x; unsigned long u;
if (control_init() == -1) die_control(); if (control_rldef(&greeting,"control/smtpgreeting",1,(char *) 0) != 1) die_control(); liphostok = control_rldef(&liphost,"control/localiphost",1,(char *) 0); if (liphostok == -1) die_control(); if (control_readint(&timeout,"control/timeoutsmtpd") == -1) die_control(); if (timeout <= 0) timeout = 1;
if (control_readint(&tarpitcount,"control/tarpitcount") == -1) die_control();
if (tarpitcount < 0) tarpitcount = 0;
x = env_get("TARPITCOUNT");
if (x) { scan_ulong(x,&u); tarpitcount = u; };
if (control_readint(&tarpitdelay,"control/tarpitdelay") == -1) die_control();
if (tarpitdelay < 0) tarpitdelay = 0;
x = env_get("TARPITDELAY");
if (x) { scan_ulong(x,&u); tarpitdelay = u; };
if (rcpthosts_init() == -1) die_control();
if (control_readint(&mfchk,"control/mfcheck") == -1) die_control(); x = env_get("MFCHECK"); if (x) { scan_ulong(x,&u); mfchk = u; }
bmfok = control_readfile(&bmf,"control/badmailfrom",0); if (bmfok == -1) die_control(); if (!constmap_init(&mapbmf,bmf.s,bmf.len,0)) die_nomem();
bmtok = control_readfile(&bmt,"control/badmailto",0); if (bmtok == -1) die_control(); if (!constmap_init(&mapbmt,bmt.s,bmt.len,0)) die_nomem();
sigsok = control_readfile(&sigs,"control/signatures",0); if (sigsok == -1) die_control();
if (control_readint(&databytes,"control/databytes") == -1) die_control(); x = env_get("DATABYTES"); if (x) { scan_ulong(x,&u); databytes = u; } if (!(databytes + 1)) --databytes;
remoteip = env_get("TCPREMOTEIP"); if (!remoteip) remoteip = "unknown"; local = env_get("TCPLOCALHOST"); if (!local) local = env_get("TCPLOCALIP"); if (!local) local = "unknown"; remotehost = env_get("TCPREMOTEHOST"); if (!remotehost) remotehost = "unknown"; remoteinfo = env_get("TCPREMOTEINFO"); relayclient = env_get("RELAYCLIENT");
#ifdef TLS if (env_get("SMTPS")) { smtps = 1; tls_init(); } else #endif dohelo(remotehost); }