qmail-amavisd integration

Description (very brief)

qmail-amavisd is a small program (annother qmail-queue replacement) allowing to set up "one-and-half"-MTA amavisd scan.

From README

I work with qmail for several years, mostly satisfied with it, however, lots of spam and viruses forced me to think of early rejection and more efficient scanning than spamc/spamd from mailfilter.

Amavis seemed to be The Right Thing, but...

qmail-scanner is unsuitable for any real mailserver. Running a perl script for each mail brings any hardware to the knees.

dual-MTA setup described somewhere on Amavis site is ugly (disclaimer: it is my personal opinion) and it will probabily not work with existing vpopmail setup.

helper-progs/amavis.c seems to be unfinished and it is totally undocumented.

So, I've recalled my C skills and put forth emacs.

The result is "one and half"-MTA setup. qmail-qsmtp.c forwards all incoming mail to 127.0.0.1:10024, logging amavis reply and possible internal errors. Address is hardcoded right now, I'll make it more configurable one day (see TODO).

Versions

Current version -- 0.94

0.94. I'll have to write down detailed description

Fixed coredump on empty envelope; still wonder how empty envelope can be received. Looks like some bug somewhere; however, so far it affected only spam.

Historical versions -- 0.91

0.90

Requirements

Features

Early rejection -- ability to reject viruses/spam during SMTP session

Fits nicely in qmail framework

Drawbacks

Hight memory requirements for running a number of amavises

3-10 seconds delay on inbound mail for spam checking; users may complaint

Bugs

Sometimes, qmail-queue.smtp receives empty envelope from qmail-smtpd. I don't understand how can it be; I couldn't reproduce this error, even with logged SMTP session. The problem seems to be persistent with some hosts; however, so far those hosts only sent SPAM.

Changes

TODO:

Quite soon

Configuration files

FreeBSD port

Not quite soon

Graph, something like mailgraph, but more qmail-oriented

Ability to pass mail from authenticated users without time-consuming amavisd check


Alex Povolotsky
Last modified: Fri Apr 2 10:38:51 MSD 2004