iptables question

Posted December 29, 2013 3.2k 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

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
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