enable CSF Firewall custom regex support
Inspiration from: enable CSF Firewall native fail2ban like support
$ wget https://github.com/tmiland/csf-custom-regex/raw/master/csf_custom_regex.sh
$ chmod +x csf_custom_regex.sh
$ ./csf_custom_regex.sh --install
- Install option will download regex.custom.pm
- Status option will run
tail -f /var/log/lfd.log | grep 'LF_CUSTOMTRIGGER'
You will see lines like: Mar 15 00:05:46 vps lfd[688]: (nginx_444) Nginx 444 [IP Adress] (CA/Canada/-): 5 in the last 3600 secs - *Blocked in csf* for 86400 secs [LF_CUSTOMTRIGGER]
Logpaths are currently hardcoded to match Debian 10 with Virtualmin.
- If Virtualmin or CSF is not installed, you will get the question to install. This will source the Virtualmin install script and CSF installer script
- Debian 10
- Debian 9 and later
- Might add Compatibility on request
- Virtualmin is required
- Might change in the future
- Code is customized from these sources:
- PayPal me
- [BTC] : 33mjmoPxqfXnWNsvy8gvMZrrcG3gEa3YDM
Sign up for web hosting using this link, and receive $100 in credit over 60 days.
*** Use at own risk ***