blob: 71a1336b050d6c865ed17946f9fd57c4ac543480 (
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
32
33
34
35
|
#!/bin/sh
#PKG reaim
#INIT 75
. /etc/rc.conf
IPT=/usr/sbin/iptables
WAN=${reaim_flags}
case $1 in
autostop) ;;
autostart)
test x"${reaim:-NO}" = x"NO" && exit 0
exec sh $0 start
;;
start)
$IPT -A input_rule -i $WAN -p tcp --dport 1863:1864 -j ACCEPT
$IPT -A input_rule -i $WAN -p tcp --dport 4443 -j ACCEPT
$IPT -A input_rule -i $WAN -p tcp --dport 5566 -j ACCEPT
$IPT -A input_rule -i $WAN -p tcp --dport 40000:40099 -j ACCEPT
reaim
;;
stop)
pkill reaim
;;
restart)
sh $0 stop
sh $0 start
;;
*)
echo "Usage: $0 {start | stop | restart}"
exit 1
;;
esac
exit $?
|