source: src/router/eop-tunnel/eop-tunnel.firewall @ 31858

Last change on this file since 31858 was 31858, checked in by brainslayer, 2 weeks ago

fix proto

  • Property svn:executable set to *
File size: 718 bytes
Line 
1#!/bin/sh
2nv=/usr/sbin/nvram
3ipt=/usr/sbin/iptables
4for i in 1 2 3 4 5 6 7 8 9 10
5do
6        if test -e "/tmp/oet/pid/${i}.pid"
7        then
8                $ipt -D FORWARD -i oet${i} -j ACCEPT 2>&1 > /dev/null
9                $ipt -D FORWARD -o oet${i} -j ACCEPT 2>&1 > /dev/null
10                $ipt -D INPUT -i oet${i} -j ACCEPT 2>&1 > /dev/null
11                $ipt -D INPUT -p 97 -s `$nv get oet${i}_rem` -j ACCEPT 2>&1 > /dev/null
12        fi
13        if [ `$nv get oet${i}_en` -eq 1 ]
14        then
15                $ipt -I INPUT -p 97 -s `$nv get oet${i}_rem` -j ACCEPT 2>&1 > /dev/null
16                if [ `$nv get oet${i}_bridged` -ne 1 ]
17                then
18                        $ipt -I FORWARD -i oet${i} -j ACCEPT 2>&1 > /dev/null
19                        $ipt -I FORWARD -o oet${i} -j ACCEPT 2>&1 > /dev/null
20                        $ipt -I INPUT -i oet${i} -j ACCEPT 2>&1 > /dev/null
21                fi
22        fi
23done
Note: See TracBrowser for help on using the repository browser.