diff --git a/fail2ban.py b/fail2ban.py index 12ae2d77..0632cdc7 100755 --- a/fail2ban.py +++ b/fail2ban.py @@ -40,8 +40,10 @@ logSys = log4py.Logger().get_instance() logFwList = list() conf = dict() -def usage(): - print "Usage: fail2ban [OPTIONS]" +def dispUsage(): + """ Prints Fail2Ban command line options and exits + """ + print "Usage: "+sys.argv[0]+" [OPTIONS]" print print "Fail2Ban v"+version+" reads log file that contains password failure report" print "and bans the corresponding IP address using iptables." @@ -57,10 +59,17 @@ def usage(): print " -r allow a max of VALUE password failure" print " -t