From b64be488902cccb3f4e10396a93777caa107b1d9 Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Fri, 12 Sep 2003 21:42:12 +0000 Subject: for tunneling, add a route for the tunneled net through the other host --- sysconfig/network-scripts/ifdown-ipsec | 2 ++ sysconfig/network-scripts/ifup-ipsec | 4 ++++ 2 files changed, 6 insertions(+) (limited to 'sysconfig/network-scripts') diff --git a/sysconfig/network-scripts/ifdown-ipsec b/sysconfig/network-scripts/ifdown-ipsec index 37e5f76f..695a71a1 100755 --- a/sysconfig/network-scripts/ifdown-ipsec +++ b/sysconfig/network-scripts/ifdown-ipsec @@ -56,6 +56,8 @@ else [ -z "$SRCNET" ] && SRCNET="$SRC/32" [ -z "$DSTNET" ] && DSTNET="$DST/32" + ip route del to $DSTNET via $DST + /sbin/setkey -c >/dev/null 2>&1 << EOF spddelete $SRCNET $DSTNET any -P out; spddelete $DSTNET $SRCNET any -P in; diff --git a/sysconfig/network-scripts/ifup-ipsec b/sysconfig/network-scripts/ifup-ipsec index 3ea68768..b474f41d 100755 --- a/sysconfig/network-scripts/ifup-ipsec +++ b/sysconfig/network-scripts/ifup-ipsec @@ -137,6 +137,8 @@ EOF [ -z "$SRCNET" ] && SRCNET="$SRC/32" [ -z "$DSTNET" ] && DSTNET="$DST/32" + ip route add to $DSTNET via $DST + /sbin/setkey -c >/dev/null 2>&1 << EOF delete $SRC $DST ah $SPI_AH_OUT; delete $DST $SRC ah $SPI_AH_IN; @@ -189,6 +191,8 @@ EOF [ -z "$SRCNET" ] && SRCNET="$SRC/32" [ -z "$DSTNET" ] && DSTNET="$DST/32" + ip route add to $DSTNET via $DST + /sbin/setkey -c >/dev/null 2>&1 << EOF spddelete $SRCNET $DSTNET any -P out; spddelete $DSTNET $SRCNET any -P in; -- cgit v1.2.1