Problem with Virus Scan Custom Function
Leonardo Helman
mailscanner at lists.com.ar
Mon Sep 17 13:05:00 IST 2007
Hi
I think this is a recurring one.
The problem:
When "Virus Scanning" is a Custom function AND
Dangerous Content Scanning is set to "Yes", MS calls each virus
scanner without looking for the Custom Function value.
The report is correct, that is, if CS returns 0 the report doesn't say
nothing about viruses
I've noticed that in
SweepViruses.pm
in the sub TryCommercial
is this code
----------
return 1 if MailScanner::Config::IsSimpleValue('virusscan') &&
!MailScanner::Config::Value('virusscan');
----------
So when virusscan is a function, scans all the batch (if it's already
opened)
a quick example to reproduce this, would be a Custom function
like
sub InitVS {
return 0;
}
and
Virus Scanning= &VS
Dangerous Content Scanning = yes
And send a virus. The virus will be scanned (not what the custom
function says), and not reported (that's good)
I'know there is a batch over there so, we don't know at this stage if
each member of the batch wants to AV or not
In ScanBach the files to scan are already created (I think this only
happens when there also other forms of content scanning)
I think "Dangerous Content Scanning" is opening the mail, and the
scanning is over all the already opened parts.
I think the quick&dirty is something like calling the same Custom
Function in "Dangerous Content Scanning" and "Virus Scanning"
Is there another way?
I thought that maybe we could check "Virus Scanning" on the ClamAVModule
"while($childname = $dir->read()) " and only check
"$dirname/$childname when is asked
If that's THE way, we should write a line or two about that in
MailScanner.conf
Saludos
--
Leonardo Helman
Pert Consultores
Argentina
More information about the MailScanner
mailing list