hi
im wondering if any one has or can save out a solid iptables template that suits imscp. i would like to have and use it as a base for me to build on?
thank you
hi
im wondering if any one has or can save out a solid iptables template that suits imscp. i would like to have and use it as a base for me to build on?
thank you
Hi
I use shorewall and shorewall6 to configure iptables. I can post the configs if you like.
Hi, please, could you post the Zone, policy, rules, interfaces and the shorewall.conf files ?
Thanks
Victor
Here you go:
Keep in mind, you need shorewall6 for ipv6 traffic / ip6tables.
shorewall.conf:
Mostly standard config, except "ADMINISABSENTMINDED" activated (see file routestopped), "ACCOUNTING" is deactivated (imscp does it already), "IP_FORWARDING" activated (for ssh forwarding and vpn)
zones:
just ignore the vpn part
interfaces:
policy:
params:
I once had multiple IPs (each with different open ports) and configured them here
rules:
- in a single ip setup you just need to write $FW instead of $FW:$IP_0
- standard ports are the imscp services except mysql but includes ssh port 22 and all the SSL ports for mail and http.
- if your server serves DNS for some domains, open port 53
- set the proftpd passive ports to what is configured in your proftpd.conf
- the rules file for ipv6 is really the same but the icmp protocol is named "ipv6-icmp"
routestopped:
if you stop* shorewall/shorewall6, the rules here are activated.
if you activate ADMINISABSENTMINDED, then open connections stay active, otherwise they would be cut off. The server can also make new connections to the internet.
* stopping shorewall means stopping all the traffic from/to the server. It's somehow an emergency brake. But be aware, this does not help against UDP DDOS attacks.
Hope it helps