SA wrote:

On Sat, 2004-11-06 at 09:49, Troels Walsted Hansen wrote:


Hi all,

I created a small plugin using the new plugin API in SpamAssassin 3.x.
The plugin connects to a local ClamAV server (through TCP) and checks
the email for virus. If a virus is found, it returns a positive return
code to indicate spam and sets the header "X-Spam-Virus: Yes
($virusname)".


I have a question here. Doesn't that require clamav to load the virus
signatures each time? If so, it would be pretty inefficient and
resource-hungry. Wouldn't the combination of
courier-maildrop/clamassassin and clamdscan be a lot faster since the
clamd daemon keeps the virus.db loaded?



The plugin connects to a running clamd daemon through a TCP socket and submits the mail for checking through the socket. It doesn't invoke clamscan or clamdscan from the commandline at all.


Using the UNIX socket that clamd listens on might be slightly more efficient, I haven't tested that.

Troels



Reply via email to