blob: c0b5b5cc641b8340c03a9743c15110547cde6205 (
plain)
- #: Allow packets for ipsec hosts to be delivered using ipsec interfaces
- if [ -n "$IPSECCONN" ]; then
- for i in $IPSECCONN; do
- eval "IPSEC_IF=\$IPSEC_IF_$i"
- eval "IPSEC_HERE=\$IPSEC_HERE_$i"
- eval "IPSEC_THERE=\$IPSEC_THERE_$i"
- case $MASQMETHOD in
- ipfwadm)
- $IPFWADM -O -a accept -W ${i%%:*} -D $IPSEC_HERE
- $IPFWADM -O -a accept -W ${i%%:*} -D $IPSEC_THERE
- ;;
- ipchains)
- $IPCHAINS -A output -j ACCEPT -i ${IPSEC_IF%%:*} -d $IPSEC_HERE
- $IPCHAINS -A output -j ACCEPT -i ${IPSEC_IF%%:*} -d $IPSEC_THERE
- ;;
- netfilter)
- $IPTABLES -A OUTPUT -j ACCEPT -o ${IPSEC_IF%%:*} -d $IPSEC_HERE
- $IPTABLES -A OUTPUT -j ACCEPT -o ${IPSEC_IF%%:*} -d $IPSEC_THERE
- ;;
- esac
- done
- fi
|