Minor problems with messages to users

Marc Perea marc.perea at ELECTRONIC-GROUP.COM
Mon Jul 15 12:45:26 IST 2002


On Fri, 12 Jul 2002 15:46:37 -0400
Denis Beauchemin <Denis.Beauchemin at USHERBROOKE.CA> wrote:

> 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...

Hmmm .... strange then, it works for me in both two ways (command line and
mailscanner). Be sure of taking care of the special characters escaping
them.

Anyway ... good luck with your modifs! :-)

Cheers

>
> 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



More information about the MailScanner mailing list