<div dir="auto" style="word-wrap:break-word">Rick,<div><br></div><div>Can you email me the complete script you came up with please? Would save me some time. <span></span><br><div>
<div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
<br>-</div><div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
Jerry Benton</div><div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
<a href="http://www.mailborder.com" target="_blank">www.mailborder.com</a></div><div style="color:rgb(0,0,0);font-family:Helvetica;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
<br></div><br>
</div>
<br><div style="direction:ltr"><div>On Jun 23, 2014, at 12:00 AM, Rick Cooper &lt;<a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;rcooper@dwford.com&#39;);" target="_blank">rcooper@dwford.com</a>&gt; wrote:</div><br><blockquote type="cite">
Could I suggest the following, it will accomidate /opt/MailScanner installs<br>as well as /etc/MailScanner installs, and it also will not overwright the<br>files if there is not a successful download. It also leaves the temp file<br>
there if there is an issue. I removed the --no-check-certificate part<br>because it&#39;s not an ssl site so there is no point in the parameter. Of<br>course this could be greatly shortened by just checking for the files and<br>
creating the links in the same fashion as the directory and if you really<br>want to be clean<br><br>MS_DIR=<br>If [ -f /opt/MailScanner/etc/phishing.safe.sites.conf ]; then<br><span style="white-space:pre-wrap">        </span>MS_DIR=/opt/MailScanner/etc/phishing.safe.sites.conf<br>
fi<br>If [ -f /etc/MailScanner/phishing.safe.sites.conf ]; then<br><span style="white-space:pre-wrap">        </span>MS_DIR=/etc/MailScanner/phishing.safe.sites.conf<br>Fi<br><br>If [ &quot;${MS_DIR}&quot; == &quot;&quot; ]; then<br>
<span style="white-space:pre-wrap">        </span>echo phishing.safe.sites.conf cannot be found<br><span style="white-space:pre-wrap">        </span>echo EXITING<br><span style="white-space:pre-wrap">        </span>exit 1<br>fi<br><br>Then use MS_DIR in a mv command since there is no chance of over writing a<br>
symlink<br><br>#!/bin/bash<br># # Mailborder update safe phishing sites<br># v4.1.3 # 20 June 2014<br># # Run this script as a user with write permissions<br># to /etc/MailScanner/phishing.safe.sites.conf<br>if [ ! -d /etc/MailScanner ]; then<br>
 echo etc/MailScanner does not exist, creating it<br> mkdir /etc/MailScanner<br> chmod 0644 /etc/MailScanner<br>fi<br><br>if [ -f  /etc/MailScanner/phishing.safe.sites.conf ]; then<br> /usr/bin/wget -O /tmp/phishing.safe.sites.conf<br>
<a href="http://phishing.mailborder.com/phishing.safe.sites.conf" target="_blank">http://phishing.mailborder.com/phishing.safe.sites.conf</a><br> ERR_CODE=$?<br> if [ &quot;$ERR_CODE&quot; == &quot;0&quot; ]; then<br>  cp -f /tmp/phishing.safe.sites.conf<br>
/etc/MailScanner/phishing.safe.sites.conf<br>  chmod 0644 /etc/MailScanner/phishing.bad.sites.conf<br>  rm -f /tmp/phishing.safe.sites.conf<br> else<br>  echo Had a problem downloading phishing.safe.sites.conf error code was<br>
$ERR_CODE<br> fi<br>else<br> echo Linking opt Based MailScanner Files<br> ln -s /opt/MailScanner/etc/phishing.safe.sites.conf /etc/MailScanner/<br> /usr/bin/wget -O /tmp/phishing.safe.sites.conf<br><a href="http://phishing.mailborder.com/phishing.safe.sites.conf" target="_blank">http://phishing.mailborder.com/phishing.safe.sites.conf</a><br>
 ERR_CODE=$?<br> if [ &quot;$ERR_CODE&quot; == &quot;0&quot; ]; then<br>  cp -f /tmp/phishing.safe.sites.conf<br>/etc/MailScanner/phishing.safe.sites.conf<br>  chmod 0644 /etc/MailScanner/phishing.bad.sites.conf<br>  rm -f /tmp/phishing.safe.sites.conf<br>
 else<br>  echo Had a problem downloading phishing.safe.sites.conf error code was<br>$ERR_CODE<br> fi<br>fi<br><br>________________________________<br><br>From: <a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;mailscanner-bounces@lists.mailscanner.info&#39;);" target="_blank">mailscanner-bounces@lists.mailscanner.info</a><br>
[mailto:<a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;mailscanner-bounces@lists.mailscanner.info&#39;);" target="_blank">mailscanner-bounces@lists.mailscanner.info</a>] On Behalf Of Jerry<br>Benton<br>Sent: Friday, June 20, 2014 9:23 PM<br>
To: MailScanner discussion<br>Subject: Phishing Update Service<br><br><br>Ok, I went a little further. There are now updated &quot;safe&quot; and &quot;bad&quot; phishing<br>sites once per day. Read more and get the scripts here if you want them. <br>
<br><a href="http://phishing.mailborder.com/" target="_blank">http://phishing.mailborder.com/</a><br><br><br><br>-<br>Jerry Benton<br><a href="http://www.mailborder.com" target="_blank">www.mailborder.com</a><br><br><br><br>
-- <br>MailScanner mailing list<br><a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;mailscanner@lists.mailscanner.info&#39;);" target="_blank">mailscanner@lists.mailscanner.info</a><br><a href="http://lists.mailscanner.info/mailman/listinfo/mailscanner" target="_blank">http://lists.mailscanner.info/mailman/listinfo/mailscanner</a><br>
<br>Before posting, read <a href="http://wiki.mailscanner.info/posting" target="_blank">http://wiki.mailscanner.info/posting</a><br><br>Support MailScanner development - buy the book off the website! <br></blockquote></div>
<br></div></div><br><br>-- <br><div dir="ltr"><div><div><br>--<br></div>Jerry Benton<br></div>Mailborder Systems<br><a href="http://www.mailborder.com" target="_blank">www.mailborder.com</a><br></div><br>