master
parent
e19a7aaf40
commit
0d44c065e6
|
@ -155,8 +155,13 @@ if [ $ROUTING ]; then
|
||||||
FWINT2=${ROUTE[2]}
|
FWINT2=${ROUTE[2]}
|
||||||
FWIP1=${ROUTE[1]}
|
FWIP1=${ROUTE[1]}
|
||||||
FWIP2=${ROUTE[3]}
|
FWIP2=${ROUTE[3]}
|
||||||
|
|
||||||
|
if [ -e "/proc/sys/net/ipv4/conf/$FWINT1/forwarding" ]; then
|
||||||
echo 1 > /proc/sys/net/ipv4/conf/$FWINT1/forwarding
|
echo 1 > /proc/sys/net/ipv4/conf/$FWINT1/forwarding
|
||||||
|
fi
|
||||||
|
if [ -e "/proc/sys/net/ipv4/conf/$FWINT2/forwarding" ]; then
|
||||||
echo 1 > /proc/sys/net/ipv4/conf/$FWINT2/forwarding
|
echo 1 > /proc/sys/net/ipv4/conf/$FWINT2/forwarding
|
||||||
|
fi
|
||||||
$IPTABLES -A FORWARD -i $FWINT1 -o $FWINT2 \
|
$IPTABLES -A FORWARD -i $FWINT1 -o $FWINT2 \
|
||||||
-s $FWIP1 -d $FWIP2 -j ACCEPT
|
-s $FWIP1 -d $FWIP2 -j ACCEPT
|
||||||
if [ ${ROUTE[4]} == "1" ]; then
|
if [ ${ROUTE[4]} == "1" ]; then
|
||||||
|
|
Loading…
Reference in New Issue