July 2017
Intermediate to advanced
434 pages
12h 59m
English
Now, combine this filter with a jail entry which blocks an IP address if too many failed INVITEs or REGISTERs are received within a certain period of time.
The /etc/jail.conf file may get overwritten when upgrading Fail2Ban. Create a /etc/fail2ban/jail.local file with the following data in it, setting the correct path to *your* freeswitch.log file (maybe yours is in /usr/local/freeswitch/log/freeswitch.log), and adjust the sender email address to your setup:
[freeswitch] enabled = true port = 5060,5061,5080,5081 filter = freeswitch logpath = /var/log/freeswitch/freeswitch.log action = iptables-allports[name=freeswitch, protocol=all] sendmail-whois[name=FreeSwitch, dest=root, sender=fail2ban@example.org] maxretry = 10 ...
Read now
Unlock full access