LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 01-31-2009, 12:00 PM   #1
jhwilliams
Senior Member
 
Registered: Apr 2007
Location: Portland, OR
Distribution: Debian, Android, LFS
Posts: 1,168

Rep: Reputation: 207Reputation: 207Reputation: 207
iptables DROP, performance effect with n lines?


Hi,

The method I've employed to protect my server is to add a -s INPUT $IPADDR -j DROP line to my iptables for each ip address that i see doing suspicious things in my logs. This list is growing. I am wondering if anyone has a better solution -- but particularly, I am wondering if this will really start to slow things down as the list gets longer. 100 hosts, 1000 hosts, 10,000 hosts? Any experience?

Thanks,
Jameson
 
Old 02-01-2009, 04:49 AM   #2
repo
LQ 5k Club
 
Registered: May 2001
Location: Belgium
Distribution: Linux Mint
Posts: 8,511

Rep: Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884Reputation: 884
what suspicious things?

you can use fail2ban, which will block these ip's for a certain time after a certain number of attempts
or you can use iptables to do the same.

for ssh:

Code:
$IPT -N SSH_CHECK
$IPT -A INPUT -p tcp --dport 22 -m state --state NEW -j SSH_CHECK
$IPT -A SSH_CHECK -m recent --set --name SSH
$IPT -A SSH_CHECK -m recent --update --seconds 60 --hitcount 4 --name SSH -j DROP
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Dramatic drop in performance Niteskye Slackware 3 01-27-2006 01:20 PM
drop in performance under load slzckboy Slackware 10 11-10-2005 04:58 PM
Redhat AS3.0 performance drop yuhuashi Red Hat 1 05-29-2005 07:15 AM
iptables - drop all -> allow needed OR allow all -> drop specific lucastic Linux - Security 5 12-21-2004 02:07 AM
XDirectFB with drop shadow effect around the windows pijulius Linux - Software 1 07-02-2003 10:39 AM


All times are GMT -5. The time now is 11:41 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration