The firewall (FW) is a key component of your server's security.
You can search Internet to get all the related theory. My aim is not to explain that over here but just to give you HOW to setup a Firewall with IpTables.
The following codes and examples are based iptables and ip6tables.
This is how a firewall works:
This is how you can use a firewall at home | work:
The firewall performs:
- Basic security check
- Security policy's enforcement
- IP, port filtering
- Port forwarding and NAT
All this knowledge is the result of years of experiments and trials. Don't hesitate to search over Internet for more advanced || simpler rules.
- How to set IPv4 as default: http://bruteforce.gr/make-apt-get-use-ipv4-instead-ipv6.html
- Working years and some co-workers help:
- Julien Rialland