# [solved] how to secure server

## mistake25

hi,

on my private server i'm running few application like ftp, ssh, samba etc.

it is possible to run some specific script, or command, after n unsuccessful logins?

eg. when someone fail to login 3 time on ftp then script ftp_login_failed.sh will run.

thanksLast edited by mistake25 on Tue Sep 14, 2010 8:03 pm; edited 1 time in total

----------

## chithanh

You may want to look into fail2ban.

But be very careful with it, you expose yourself to DoS attacks if fail2ban is not configured properly.

----------

## mistake25

thanks this is what i wanted

----------

