<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body bgcolor=white lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I’m with you Chuck.  Sticking those rules in an init script seems like a nice clean way to monitor and block.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Thanks Gerald<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><div style='border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt'><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> blueonyx-bounces@mail.blueonyx.it [mailto:blueonyx-bounces@mail.blueonyx.it] <b>On Behalf Of </b>Chuck Tetlow<br><b>Sent:</b> Wednesday, January 09, 2013 1:46 PM<br><b>To:</b> BlueOnyx General Mailing List<br><b>Subject:</b> [BlueOnyx:11952] Re: Blocking brute force SSH login attempts<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Interesting Gerald.  VERY interesting! <br><br>Those rules use some stuff that is new to me.  And if those rules work - they'd be a GREAT asset to prevent hacking attempts.  Much better than DFIX or mod_abl, since they do it in real-time and IPTables runs more efficiently than those programs in user-space. <br><br>Have you tested these rules Gerald?  Because if those rules work as intended - this could be the answer to our problems with people trying to hack in via FTP and POP.  I'm not concerned about SSH, because I got tired of hacking attempts years ago and blocked TCP 22 and 23 at our front-door router (and switched SSH to a odd-ball port for access).  But I think we're all still seeing those multiple-attempt-per-second scans trying to get valid usernames and guess passwords.  These IPTables rules could put a end to that, and the DOS it causes when Dovecot goes down. <br><br>Oh, and have you tried to log those actions?  Like logging the DROP before doing it?  I'd like to see some logging actions on what IPTables drops - both so we could know its working and so we could insure that its not the cause of a user issue. <br><br>Thanks Gerald.  I'm looking forward to playing with these rules and maybe improving our security. <br><br><br><br>Chuck <br><br><br><span style='font-size:10.0pt'><br><br><b>--------- Original Message -----------</b> <br>From: Gerald Waugh <<a href="mailto:gwaugh@frontstreetnetworks.com">gwaugh@frontstreetnetworks.com</a>> <br>To: BlueOnyx General Mailing List <<a href="mailto:blueonyx@mail.blueonyx.it">blueonyx@mail.blueonyx.it</a>> <br>Sent: Wed, 09 Jan 2013 11:23:41 -0600 <br>Subject: [BlueOnyx:11950] Re: Blocking brute force SSH login attempts <br><br>> On 01/09/2013 08:07 AM, James wrote: <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'><br>> <br>> Is there a simple way in BlueOnyx to auto-block hosts that fail to login via SSH too many times?  Something similar to the Failed Logins settings for the BlueOnyx login page but for SSH? <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt'>I use catches attacks in real times, below uses 8 attempts in 60 seconds, of course you can change those parameters <br>> <br>> /sbin/iptables -A INPUT -i eth0 -p tcp --dport 22 -m state --state NEW -m recent --set --name SSH <br>> <br>> /sbin/iptables -A INPUT -i eth0 -p tcp --dport 22 -m state --state NEW -m recent --update --seconds 60 --hitcount 8 --rttl --name SSH -j DROP <br>> <br>> -- <br>> Gerald <br><b>------- End of Original Message -------</b> </span><o:p></o:p></p></div></div></body></html>