Just thought I would tell a little story that happened to me recently.
Virus scanning stopped working after my last config change.  Unfortunately I
did not notice it until quite a while later all the while virus scanning was
not getting envoked.  Nothing bad happened because I have virus scanning on
the desktop too but still scary that messing the entries below up would
result in no virus scanning.

It boiled down to not understanding perl variables enough to setup
virus_lovers_maps and bypass_virus_checks_maps correctly.  I apparently did
not look at the examples long enough before digging in.

Starting amavisd-new showed 'ANTI-VIRUS code      NOT loaded' and av-scan-2
disappeared from the timing logs but I didn't notice.

I had:

@bypass_virus_checks_maps = (
  '[EMAIL PROTECTED]' => 1,
);

@virus_lovers_maps = (
  '[EMAIL PROTECTED]' => 1,
);

The result caused the antivirus code to not load.  Of course the obvious
thing that I know was wrong but did it anyway was that ' will not allow the
$mydomain variable to work.  I don't see how I overlooked that.

I changed it to the below config after looking at the samples again:

@bypass_virus_checks_maps = (
 { "[EMAIL PROTECTED]" => 1,
 },
);

@virus_lovers_maps = (
  { "[EMAIL PROTECTED]" => 1,
  },
);

AV is working again.  I assume it was the missing {} that disabled antivirus
completely but I am not perl savy enough to understand what value
amavisd-new got when reading it without them.  Lesson learned... be VERY
VERY careful when modifying these variables :).
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
AMaViS-user mailing list
AMaViS-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/

Reply via email to