Fail2ban not working

Support forum for the ViciBox ISO Server Install and ISO LiveCD Demo

Moderators: enjay, williamconley, Staydog, mflorell, MJCoate, mcargile, Kumba

Fail2ban not working

Postby DefLeppard » Mon Apr 14, 2014 4:18 am

I am using Vicibox 5.0.3 Preload x64 instance. Vicidial 2.8b0.5, SVN version 2040.
VERSION: 2.8-417a
BUILD: 131019-0849

I have installed fail2ban and added a jail called asterisk-iptables but it doesn't seem to work. It seems that there is no service /etc/init.d/fail2ban. There is a command called fail2ban-server which when run shows the following:
2014-04-14 04:47:07,342 fail2ban.server [12704]: INFO Starting Fail2ban v0.8.12
2014-04-14 04:47:07,342 fail2ban.server [12704]: INFO Starting in daemon mode

But there are no rules added in iptables. I tried to test using a soft phone with incorrect credentials and my IP was not banned. Following is my jail config. I am using stock filter.d/asterisk.conf
[asterisk-iptables]
# if more than 4 attempts are made within 6 hours, ban for 24 hours
enabled = true
filter = asterisk
action = iptables-allports[name=ASTERISK, protocol=all]
sendmail[name=ASTERISK, dest=xxx@gmail.com,
sender=fail2ban@xyz.abc.com]
logpath = /var/log/asterisk/messages
maxretry = 4
findtime = 21600
bantime = 86400

Please advise how I can get Fail2ban working.
DefLeppard
 
Posts: 85
Joined: Thu May 20, 2010 8:28 pm

Re: Fail2ban not working

Postby williamconley » Wed Apr 16, 2014 11:40 pm

My advice: DON'T get it working.

http://www.viciwiki.com/index.php/DGG
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # 888-883-8488 # +44(203) 769-2294
williamconley
 
Posts: 20438
Joined: Wed Oct 31, 2007 4:17 pm
Location: Bartow, FL (In the boondocks)

Re: Fail2ban not working

Postby DefLeppard » Wed Apr 16, 2014 11:46 pm

Good post. But how do I allow at-home agents to access the public dialer without having to whitelist their IP each time? In some cases, multiple times a day.
DefLeppard
 
Posts: 85
Joined: Thu May 20, 2010 8:28 pm

Re: Fail2ban not working

Postby williamconley » Thu Apr 17, 2014 5:10 pm

Apparently you didn't notice what the DYNAMIC portion of DGG (aka: DYNAMIC good guys) is for. Perhaps you should try again? :)
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # 888-883-8488 # +44(203) 769-2294
williamconley
 
Posts: 20438
Joined: Wed Oct 31, 2007 4:17 pm
Location: Bartow, FL (In the boondocks)


Return to ViciBox Server Install and Demo

Who is online

Users browsing this forum: No registered users and 99 guests