94d5565cca
Per http://article.gmane.org/gmane.comp.embedded.openwrt.devel/7339 please find attached the referenced missing lsm_script. Signed-off-by: Brian J. Murrell <brian <at> interlinx.bc.ca> git-svn-id: svn://svn.openwrt.org/openwrt/packages@25613 3c298f89-4303-0410-b956-a3cf2f4a3e73
34 lines
615 B
Bash
34 lines
615 B
Bash
#!/bin/sh
|
|
|
|
STATE=${1}
|
|
NAME=${2}
|
|
CHECKIP=${3}
|
|
DEVICE=${4}
|
|
WARN_EMAIL=${5}
|
|
REPLIED=${6}
|
|
WAITING=${7}
|
|
TIMEOUT=${8}
|
|
REPLY_LATE=${9}
|
|
CONS_RCVD=${10}
|
|
CONS_WAIT=${11}
|
|
CONS_MISS=${12}
|
|
AVG_RTT=${13}
|
|
|
|
if [ -f /usr/share/shorewall-lite/lib.base ]; then
|
|
VARDIR=/var/lib/shorewall-lite
|
|
STATEDIR=/etc/shorewall-lite
|
|
else
|
|
VARDIR=/var/lib/shorewall
|
|
STATEDIR=/etc/shorewall
|
|
fi
|
|
|
|
[ -f ${STATEDIR}/vardir ] && . ${STATEDIR}/vardir
|
|
|
|
[ ${STATE} = up ] && state=0 || state=1
|
|
|
|
echo $state > ${VARDIR}/${DEVICE}.status
|
|
|
|
/sbin/shorewall-lite restart -f >> /var/log/lsm 2>&1
|
|
|
|
/sbin/shorewall-lite show routing >> /var/log/lsm
|