I am using Mailmonitor from Sophos on RH Linux. The quarantined messages are stored under /var/spool/mmsmtp/quarantine folder. Since quarantined messages are increasing day by day, I have written a small script to view header from each qarantine file and to release if it is a good one.
I hope it will be useful to all sophos users. Any suggestions to improve this are welcome.
--Krishna
--------------------<Start Script>-------------------------
#!/bin/sh
# Script to Release good mails from the quarantine directory
# after viewing the subject line
# Written by [EMAIL PROTECTED]
# Version 2.0 (20102003)
clear
cd /var/spool/mmsmtp/quarantine
files=`ls -1 |wc -l`
if [ "$files" -gt "0" ];
then
for i in qrt.*
do
echo
echo
echo "Enter y to release, q to quit or <Enter> to Skip"
opt='n'
echo $i
grep "Virus identity found" $i >/dev/null 2>&1
if [ $? != 0 ]; then
more $i | grep "Subject:"
more $i | grep "Scanning part"
more $i | grep "executable found"
read opt
case $opt in
y) qm $i release delete
;;
Y) qm $i release delete
;;
q) exit
;;
esac
else
echo "Virus found in message" $i
fi
done
echo
echo
echo
echo "Clear all quarantined messages [y/n] ?"
opt='n'
read opt
case $opt in
y) rm -f *
;;
Y) rm -f *
;;
esac
else
echo "No mails to release or delete"
fi
-------------------------<End Script>---------------------------_________________________________________________________________
MSN Hotmail now on your Mobile phone. http://server1.msn.co.in/sp03/mobilesms/ Click here.
------------------------------------------------------- This SF.net email is sponsored by OSDN developer relations Here's your chance to show off your extensive product knowledge We want to know what you know. Tell us and you have a chance to win $100 http://www.zoomerang.com/survey.zgi?HRPT1X3RYQNC5V4MLNSV3E54 _______________________________________________ linux-india-help mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/linux-india-help
