KAM.cf.sh script is not working
mark at msapiro.net
Sun Jan 13 04:10:39 GMT 2013
The KAM.cf.sh script downloaded from
http://www.mailscanner.info/files/4/KAM.cf.sh fails to update the latest
The script searches for a line at the end of the downloaded file
matching the pattern '^#.*EOF' to determine if the downloaded file is
complete. If it doesn't find that line, it doesn't update the working file.
It seems that the latest KAM.cf file has a '#END' line rather than
'#EOF' to indicate the end. Thus the script thinks the download was
This patch fixes the problem.
--- .cron/KAM.cf.sh.orig 2009-09-08 08:41:50.000000000 -0700
+++ .cron/KAM.cf.sh 2013-01-12 18:08:15.000000000 -0800
@@ -27,7 +27,7 @@
echo It completed okay.
if [ -r KAM.cf.backup ]; then
if [ KAM.cf -nt KAM.cf.backup ]; then
- if ( tail -10 KAM.cf | grep -q '^#.*EOF' ); then
+ if ( tail -10 KAM.cf | grep -qE '^#.*(EOF|END)' ); then
echo It succeeded, so make a backup
cp -f KAM.cf KAM.cf.backup
Mark Sapiro <mark at msapiro.net> The highway is for gamblers,
San Francisco Bay Area, California better use your sense - B. Dylan
More information about the MailScanner