Solved

Having trouble denying an ip.

Posted on 2009-03-31
7
188 Views
Last Modified: 2013-12-16
I'm running linux/apache, and I'm using this to block an ip

iptables -A INPUT -s 85.158 -j DROP

But my mail filter program still says it's still getting connections from that ip, and it overwhelms the system:

Mar 31 08:37:19 [1267]: Rejected connection from 85.158.138.179:11449 (busy), ceiling is 5 slots
Mar 31 08:37:19 [1267]: Rejected connection from 85.158.138.179:55879 (busy), ceiling is 5 slots

I also use apf, and have blocked it through that,

/usr/local/sbin/apf -d 85.158.

but it's still getting through.

Any ideas on what to do or why this isn't working?

Does iptables have to be restarted or anything?  If so, how?

thanks,  Chris
0
Comment
Question by:St_Aug_Beach_Bum
  • 4
  • 3
7 Comments
 
LVL 29

Expert Comment

by:fosiul01
ID: 24028955
yes, you need to save iptables rules after inserting

then restart the iptables

0
 

Author Comment

by:St_Aug_Beach_Bum
ID: 24029041
Thank you, how do I do that?
0
 
LVL 29

Accepted Solution

by:
fosiul01 earned 500 total points
ID: 24029065
service iptables save
service iptables restart

0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Closing Comment

by:St_Aug_Beach_Bum
ID: 31564816
ah, thank you, that seems to have done it!  dam spammers!
0
 
LVL 29

Expert Comment

by:fosiul01
ID: 24029323
are you trying to add those Ip one by one by hand ??

then you will go mad!!

use fail2ban, or portsentry

any attemept more then 3 or 4 times, those will block those Ip automaticaly
0
 

Author Comment

by:St_Aug_Beach_Bum
ID: 24029475
Thank you, normally I don't have to, my spam program, mailstripper, takes care of things pretty well.  This was move of a denial of service type thing (I guess), just overwhelming my server with junk mail, more than it could handle, so legit mails couldn't get through.

I'll take a look at these programs right now.  
0
 

Author Comment

by:St_Aug_Beach_Bum
ID: 24029527
Not saying it was a dos attack on purpose, but the amount of spam coming from that ip had that effect on my mail services.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Network Interface Card (NIC) bonding, also known as link aggregation, NIC teaming and trunking, is an important concept to understand and implement in any environment where high availability is of concern. Using this feature, a server administrator …
SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question