Minor problems with messages to users
Denis Beauchemin
Denis.Beauchemin at USHERBROOKE.CA
Fri Jul 12 20:46:37 IST 2002
Marc,
I tried to modify mcafeewrapper:
exec ${PackageDir}/$prog -d $datDIR "$@" | sed 's-^.*/--'
It worked OK at the command line (got the file name and the virus found)
but the line disappeared altogether in MailScanner... not what I
wanted...
I also tried to modify sweep.pl:
$lastline =~ s/$BaseDir\/*\w+\///;
but it didn't work either (I still got the last dir part).
Denis
On Thu, 2002-07-11 at 11:41, Marc Perea wrote:
> On Thu, 11 Jul 2002 10:04:37 -0400
> Denis Beauchemin <Denis.Beauchemin at USHERBROOKE.CA> wrote:
>
> > Hi,
> >
> > I am experimenting with MailScanner and I have a few problems:
> >
> > 1- using McAfee, when a virus is found I get a line saying so but the
> > line contains the message ID part of the PATH:
> > Résultats de l'antivirus:
> > /g69IuTY08361/VALUE.exe Found the W32/Klez.h at MM virus !!!
> >
> > I would like it to read:
> > VALUE.exe Found the W32/Klez.h at MM virus !!!
> >
> > How could this be done? I believe it must come from ProcessMcAfeeOutput
> > in sweep.pl, I guess we would have to modify $lastline =~ s/$BaseDir//;
> > for something else containing the message ID, but what?
>
> My two cents :
>
> Some time ago I was on a similar problem, i didn't want to reveal the path
> to the message, so I modified with this extremely simple trick the
> f-protwrapper shell script (Hence, you don't have to touch any mailscanner
> core perl-function) :
>
> hiddenpath=/usr/local/mailscanner/var
> exec ${PackageDir}/$Scanner $ScanOptions "$@" | sed "s%$hiddenpath%%g"
>
> You can always make a different regular expression to suit your needs.
> For example that one should work for your needs :
> "s%\/[a-zA-Z0-9]*\/\(.*\)%\1%"
>
> Hope this helps to you.
>
> --
> Marc Perea - System Administration Staff
> Mail: marc.perea at electronic-group.com
> Tel: (+34) 93 600 23 23
> Fax: (+34) 93 600 23 10
> ----------------
> Electronic Group - http://www.electronic-group.com
>
--
Denis Beauchemin, analyste
Université de Sherbrooke, S.T.I.
T: 819.821.8000x2252 F: 819.821.8045
More information about the MailScanner
mailing list