iptables question

December 29, 2013 1.5k views
I have noticed a bot trying a brute force on one of my CMS's. When I try to add the IP address with
iptables -A INPUT -s -j DROP
it shows in iptables as
DROP    all   --   anywhere
and the ip is still able to connect to the server. Am I doing something wrong with adding the IP? Can I add the IP and not have the host for that IP show in iptables? Maybe that has something to do with it. Thank you
2 Answers
Try adding it to the top of the chain:

Delete the old rule:
iptables -D INPUT -s -j DROP

Re-add it:
iptables -I INPUT -s -j DROP
Yep that worked. Had a brain fart there for a second.

Thank you
Have another answer? Share your knowledge.