Sam Carleton wrote:
Folks, I am trying to figure out the filewall script that SuSE provides to get the firewall going. There is one line:
if test -f /proc/net/ip_fwchains -a `cat /proc/sys/net/ipv4/ip_forward` -eq 1 ; then ... fi
Can someone enlighten me as to what is going on here. I know that they are testing for equality to 1, but /proc/net/ip_fwchains is not a script or a program, what is the part:
/proc/net/ip_fwchains -a `cat /proc/sys/net/ipv4/ip_forward`
For that matter what is the /proc/net/ip_fwchains and what is the /proc/sys/net/ipv4/ip_forward?
I can't give you details as I don't use a firewall but the line that you quote is very simple, it checks for the existance of a file /proc/net/ip_fwchains and the contents of another /proc/sys/net/ipv4/ip_forward. I presume that the former indicates that ip_fwchains is operational and that the latter is the current state of ip forwarding so that the total line reads if fwchains is operational and ip forwarding is enabled then The important part to remember is that `` is equal to the result of evaluating the command enclosed. /Michael -- To unsubscribe send e-mail to suse-linux-e-unsubscribe@suse.com For additional commands send e-mail to suse-linux-e-help@suse.com Also check the FAQ at http://www.suse.com/Support/Doku/FAQ/