summaryrefslogtreecommitdiff
path: root/package/iptables/files/firewall6.init
blob: bedb639a94fa3053ef6fdd2b75079e59c1f51ce3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/bin/sh
#PKG iptables
#INIT 45
. /etc/rc.conf

case $1 in
autostop) ;;
autostart)
	test x"${firewall6:-NO}" = x"NO" && exit 0
	exec sh $0 start
	;;
start)
	. /etc/firewall6.conf
	;;
stop)
	### Clear tables
	ip6tables -F
	ip6tables -X
	ip6tables -P INPUT ACCEPT
	ip6tables -P FORWARD ACCEPT
	ip6tables -P OUTPUT ACCEPT
	;;
restart)
	sh $0 stop
	sh $0 start
	;;
*)
	echo "Usage: $0 {start | stop | restart}"
	;;
esac
exit $?