I need an urgent solution using Amavis and Qmail on Linux.

I have had a look at the patches that Christopher Seawood
<[EMAIL PROTECTED]>  has supplied but I get errors.
Has anyone successfully applied these patches?
 I get a "malformed header on line 5"
( # - if "do_log" is set to "yes"                #)

------  Found this from the archives  -----

On Thu, 28 Oct 1999, Gordon Smith wrote:

> If anyone has had any success with Amavis, I'd be interested to see
how you did
> it. With the latest (pre6) qmail passes the message to the script,
which checks
> the message for viruses, but the script never passes the message back.
Aargh! I
> get a "no local delivery program available" error.
> I think that basename is not returning the calling program id
correctly, but
> I'm not sure. If anyone has already fixed this, please let me know.
Otherwise
> I'll post a fix here once I figure out whats going on  :-)

The default qmail setup for amavis was slightly horked.  You'll need to
apply the attached patch & configure it with: --enable-qmail
--enable-x-header=no.  Once you have it installed, do:

cd /var/qmail/bin
mv qmail-remote qmail-remote-real
mv qmail-local qmail-local-real
ln -s /usr/sbin/scanmails qmail-remote
ln -s /usr/sbin/scanmails qmail-local

This will allow you to scan all incoming and outgoing mail for viruses.
If you do not feel comfortable moving the binaries around, you can just
add:
| /usr/sbin/scanmails $SENDER $RECEIPIENT
to /var/qmail/defaultdelivery/rc .

The attached patch fixes the following problems:

1. Should check $sender & $receiver against $SENDER & $RECEIPIENT
instead
of $2 & $7.
2. Do not attempt to log to the logfile if $do_log != 'yes'.
3. Since qmail doesn't use the default $deliver program, do not check
for
$deliver when attempting to pass on the mail.

I'm not sure why using formail to add the X-AntiVirus: header doesn't
work so always I disabled it.  I think the proper step may be to
reinvoke
qmail-inject but I'm not sure how that would work.

- cls


--- amavis-0.2.0-pre6/src/scanmails/scanmails.in.cls    Tue Jul 20
12:28:52 1999
+++ amavis-0.2.0-pre6/src/scanmails/scanmails.in        Mon Oct 25
13:16:01 1999
@@ -103,6 +103,7 @@
 # - if "do_log" is set to "yes"                #
 ################################################
 var_log=@var_log@
+systemlogdir=${var_log}/scanmails/
 do_log=@do_log@
 do_syslog=@do_syslog@
 syslog_level=@syslog_level@
@@ -242,11 +243,11 @@
 receiver=`echo ${RECEIPIENT} | ${sed} -e "s/[\\\`\\\\\$\(\)]//g"`
 sender=`echo ${SENDER} | ${sed} -e "s/[\\\`\\\\\$\(\)]//g"`
<snip>
------ End ------

Reply via email to