aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Nottingham <notting@redhat.com>2004-03-16 23:49:05 +0000
committerBill Nottingham <notting@redhat.com>2004-03-16 23:49:05 +0000
commitdd2047c58ee503da2ec812f9b14a7c56e889191c (patch)
tree3a630c9a93f9d3063b0cefb65c2ce65b9c8180ab
parent99229a343aa5bb777dd6f8a69978f6de26282024 (diff)
downloadinitscripts-dd2047c58ee503da2ec812f9b14a7c56e889191c.tar
initscripts-dd2047c58ee503da2ec812f9b14a7c56e889191c.tar.gz
initscripts-dd2047c58ee503da2ec812f9b14a7c56e889191c.tar.bz2
initscripts-dd2047c58ee503da2ec812f9b14a7c56e889191c.tar.xz
initscripts-dd2047c58ee503da2ec812f9b14a7c56e889191c.zip
allow for no AH SPI (#116922, <felipe_alfaro@linuxmail.org>)
-rwxr-xr-xsysconfig/network-scripts/ifup-ipsec8
1 files changed, 4 insertions, 4 deletions
diff --git a/sysconfig/network-scripts/ifup-ipsec b/sysconfig/network-scripts/ifup-ipsec
index 17361bc7..3dafd9f0 100755
--- a/sysconfig/network-scripts/ifup-ipsec
+++ b/sysconfig/network-scripts/ifup-ipsec
@@ -108,10 +108,10 @@ if [ "$KEYING" = "manual" ]; then
if [ "$MODE" = "host" ]; then
/sbin/setkey -c >/dev/null 2>&1<< EOF
-delete $SRC $DST ah $SPI_AH_OUT;
-delete $DST $SRC ah $SPI_AH_IN;
-delete $SRC $DST esp $SPI_ESP_OUT;
-delete $DST $SRC esp $SPI_ESP_IN;
+${SPI_AH_OUT:+delete $SRC $DST ah $SPI_AH_OUT;}
+${SPI_AH_IN:+delete $DST $SRC ah $SPI_AH_IN;}
+${SPI_ESP_OUT:+delete $SRC $DST esp $SPI_ESP_OUT;}
+${SPI_ESP_IN:+delete $DST $SRC esp $SPI_ESP_IN;}
spddelete $SRC $DST any -P out;
spddelete $DST $SRC any -P in;