Linux-Iptables-Firewall-Server
A shell script on iptables rules for a webserver (no need to use APF or CSF) just run this script from /etc/rc.local and you are done. Save following script as /root/scripts/fw.start:
[root@linux ~ ] mkdir /root/scripts
[root@linux ~ ] cd /root/scripts
[root@linux ~ ] wget https://github.com/lyarinet/Linux-Iptables-Firewall-Server/blob/main/start.zip
[root@linux ~ ] wget https://github.com/lyarinet/Linux-Iptables-Firewall-Server/blob/main/stop.zip
[root@linux ~ ] unzip start.zip
[root@linux ~ ] unzip stop.zip
[root@linux ~ ] chmod +x * .sh
Now edit firewall as per your requirements:
[root@linux ~ ] nano start.sh
[root@linux ~ ] echo ' /root/scripts/start.sh' >> /etc/rc.local
[root@linux ~ ] /root/scripts/start.sh
[root@linux ~ ] /root/scripts/stop.sh