#!/bin/sh -x
apt-get install libwww-perl liblwp-protocol-https-perl libgd-graph-perl -y;
cd /usr/src
rm -fv csf.tgz
wget https://download.configserver.com/csf.tgz
tar -xzf csf.tgz
cd csf
chmod 0755 install.sh
sh install.sh
/usr/sbin/csf -x
/usr/bin/wget repo.zarat.dev/csf/csf2.conf -O /etc/csf/csf.conf;
/usr/bin/wget repo.zarat.dev/csf/csf.ignore -O /etc/csf/csf.ignore;
/usr/bin/wget repo.zarat.dev/csf/csf.rignore -O /etc/csf/csf.rignore;
/usr/bin/wget repo.zarat.dev/csf/regex.custom.pm -O /usr/local/csf/bin/regex.custom.pm;
/usr/bin/ln -s /usr/local/csf/bin/regex.custom.pm /etc/csf;
/usr/sbin/csf -e;
/usr/bin/systemctl restart csf;
/usr/bin/systemctl restart lfd;
csf -u --update;
csf -e;