Move detection code to separate scripts for easy customization
parent
afedda2201
commit
517d935340
|
@ -513,6 +513,9 @@ if [ "$PORTFW" ] && [ "$NAT" ]; then
|
||||||
if [ "$SRCIP" ]; then
|
if [ "$SRCIP" ]; then
|
||||||
SRCIP="-s ${SRCIP}"
|
SRCIP="-s ${SRCIP}"
|
||||||
fi
|
fi
|
||||||
|
if [ ! "$DSTIP" ]; then
|
||||||
|
DSTIP="$EXTIP"
|
||||||
|
fi
|
||||||
#PORTADD=( ${i//:/ } )
|
#PORTADD=( ${i//:/ } )
|
||||||
$IPTABLES -A PREROUTING -t nat ${DSTIF} -p ${DSTPROTO} ${SRCIP} \
|
$IPTABLES -A PREROUTING -t nat ${DSTIF} -p ${DSTPROTO} ${SRCIP} \
|
||||||
--dport ${DSTPORT} -d ${DSTIP} -j DNAT --to \
|
--dport ${DSTPORT} -d ${DSTIP} -j DNAT --to \
|
||||||
|
|
Loading…
Reference in New Issue