@@ -29,8 +29,6 @@ BADURL='https://phishing.mailscanner.info/phishing.bad.sites.conf.gz';
29
29
SAFEURL=' https://phishing.mailscanner.info/phishing.safe.sites.conf.gz' ;
30
30
MSSTARTSCRIPT=' /etc/init.d/mailscanner' ;
31
31
MSSERVICENAME=' mailscanner.service' ;
32
- PIDFile=` ms-peek ' PID file' $CONFIGDIR /MailScanner.conf`
33
-
34
32
DEBUG=0
35
33
36
34
PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/etc:/usr/local/bin:/usr/sfw/bin
113
111
bad_updated=1;
114
112
115
113
if [ $CURLORWGET = ' curl' ]; then
116
- curl -S -A " msv5 Update Script v0.2.0 " -z $CONFIGDIR /phishing.bad.sites.conf.master.gz -o $CONFIGDIR /phishing.bad.sites.conf.master.gz $BADURL & > /dev/null
114
+ curl -S -A " msv5 Update Script v0.3.1 " -z $CONFIGDIR /phishing.bad.sites.conf.master.gz -o $CONFIGDIR /phishing.bad.sites.conf.master.gz $BADURL & > /dev/null
117
115
if [ " $? " = " 0" ]; then
118
116
gunzip -f $CONFIGDIR /phishing.bad.sites.conf.master.gz
119
117
[ $DEBUG -eq 1 ] && echo Check or download phishing.bad.sites.conf.master completed OK.
152
150
153
151
if [ $CURLORWGET = ' wget' ]; then
154
152
echo Trying wget....
155
- wget -q --user-agent=" msv5 Update Script v0.2.0 " --no-check-certificate -N -O phishing.bad.sites.conf.master.gz $BADURL
153
+ wget -q --user-agent=" msv5 Update Script v0.3.1 " --no-check-certificate -N -O phishing.bad.sites.conf.master.gz $BADURL
156
154
if [ " $? " = " 0" ]; then
157
155
gunzip -f $CONFIGDIR /phishing.bad.sites.conf.master.gz
158
156
[ $DEBUG -eq 1 ] && echo Check or download phishing.bad.sites.conf.master completed OK.
219
217
safe_updated=1;
220
218
221
219
if [ $CURLORWGET = ' curl' ]; then
222
- curl -S -A " msv5 Update Script v0.2.0 " -z $CONFIGDIR /phishing.safe.sites.conf.master.gz -o $CONFIGDIR /phishing.safe.sites.conf.master.gz $SAFEURL & > /dev/null
220
+ curl -S -A " msv5 Update Script v0.3.1 " -z $CONFIGDIR /phishing.safe.sites.conf.master.gz -o $CONFIGDIR /phishing.safe.sites.conf.master.gz $SAFEURL & > /dev/null
223
221
if [ " $? " = " 0" ]; then
224
222
gunzip -f $CONFIGDIR /phishing.safe.sites.conf.master.gz
225
223
[ $DEBUG -eq 1 ] && echo Check or download phishing.safe.sites.conf.master completed OK.
258
256
259
257
if [ $CURLORWGET = ' wget' ]; then
260
258
echo Trying wget....
261
- wget -q --user-agent=" msv5 Update Script v0.2.0 " --no-check-certificate -N -O phishing.safe.sites.conf.master.gz $SAFEURL
259
+ wget -q --user-agent=" msv5 Update Script v0.3.1 " --no-check-certificate -N -O phishing.safe.sites.conf.master.gz $SAFEURL
262
260
if [ " $? " = " 0" ]; then
263
261
gunzip -f $CONFIGDIR /phishing.safe.sites.conf.master.gz
264
262
[ $DEBUG -eq 1 ] && echo Check or download phishing.safe.sites.conf.master completed OK.
@@ -324,7 +322,7 @@ updated=$(($bad_updated + $safe_updated));
324
322
325
323
if [ $updated -ge 1 ]; then
326
324
if [ " $ms_cron_ps_restart " = " 1" ]; then
327
- if [ ! -f /var/lock/subsys/MailScanner.off -a -f $PIDFile ]; then
325
+ if [ ! -f /var/lock/subsys/MailScanner.off ]; then
328
326
logger -p $SYSLOG .info -t ms-update-phishing restart MailScanner....
329
327
if [ -d /etc/systemd ]; then
330
328
systemctl restart $MSSERVICENAME > /dev/null 2>&1
0 commit comments