Auto detect and auto shutout password crack attempts

Is it at all possible to have a system that auto-detects password crack attempts and then auto-lock any further access from that IP for a period of time (configurable, so you can say that 5 failed attempts within a period of 1 minute = a crack attempt, then lock/ban that IP for 30 minute etc?)  It would obviously help to have something "sentralized" that can handle any applications' password checking, SSH, FTP, SMTP etc etc. so that all services are protected by this "time-dealy" lock?
LVL 17
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

you either need to tell this delay each of your services (ssh, ftp, etc.), or you can use iptables with the --limit (and some other) options to detect connect requests within a given time intervall

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial

   Password attend limitation is in
password    required      /lib/security/ retry=5

   I'm not sure PAM can check the IP and ban it for 30 minutes.

psimationAuthor Commented:
My system already has the retry=3 set, yet I still see more than 3000 attempts on root account from one source. What is the "supposed" action when retry reaches 3?
I believe that after 3 attempts, even if you get the right password, it is ignores and treated as incorrect. Logging continues in order to help anyone trying to examine what happened at a later date.

The reason for this is that ideally a good authentication system should never change the reaction that the attacker sees.  If the attacker starts getting any form of feedback, he knows that he has done something and can reallocaet the resources that he is using, or improve his attacking process.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux Security

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.