EFW Support

Support => General Support => Topic started by: psitech on Tuesday 03 April 2012, 09:54:36 am



Title: Firewall Redirect
Post by: psitech on Tuesday 03 April 2012, 09:54:36 am
Hi, i have a squid with authentication and i want to create a rule for GREEN interface to everithing in port 80 redirect to port 3128, i know the command ( iptables -t nat -A PREROUTING -i br0 -p tcp --dport 3128 -j REDIRECT --to 3128 ) but where i can put this in endian to every reboot its work ?


Title: Re: Firewall Redirect
Post by: kashifmax on Tuesday 03 April 2012, 07:37:54 pm
Hi, i have a squid with authentication and i want to create a rule for GREEN interface to everithing in port 80 redirect to port 3128, i know the command ( iptables -t nat -A PREROUTING -i br0 -p tcp --dport 3128 -j REDIRECT --to 3128 ) but where i can put this in endian to every reboot its work ?

Method 1
1) Make a script and link to /etc/init.d/
2) Use chkconfig command to add and load on specific runlevel.

Method 2
1) Add the command in file rc.local, but I didn't found rc.local in EFW 2.5...


Title: Re: Firewall Redirect
Post by: psitech on Tuesday 03 April 2012, 10:04:34 pm
I create a exec file in /etc/rc.d/start/customfirewall  i have to enable somthing in initialization to exec any file in this folder ?