From 55c8a5e54d3a758b2aa64f52ec3a5549ad4d5c7c Mon Sep 17 00:00:00 2001 From: Stig Thormodsrud Date: Sun, 27 Jul 2008 15:35:11 -0700 Subject: Fix ipv6 blackhole route. --- .../static/route6/node.tag/blackhole/node.def | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/templates/protocols/static/route6/node.tag/blackhole/node.def b/templates/protocols/static/route6/node.tag/blackhole/node.def index aaeab5b6..9e14a628 100644 --- a/templates/protocols/static/route6/node.tag/blackhole/node.def +++ b/templates/protocols/static/route6/node.tag/blackhole/node.def @@ -1,11 +1,14 @@ help: Set to silently discard pkts when matched delete:expression: "touch /tmp/static.$PPID" -end:expression: "if [ -f \"/tmp/static.$PPID\" ]; then \ - ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"no ip route $VAR(../@) null0\" ; \ - rm /tmp/static.$PPID; \ - else \ - if [ -n \"$VAR(./distance/@)\" ]; then \ - DIST=\"$VAR(./distance/@)\"; \ - fi; \ - ${vyatta_sbindir}/vyatta-vtysh.pl -c \"configure terminal\" -c \"ip route $VAR(../@) null0 $DIST \" ; \ - fi; " + +end: if [ -f "/tmp/static.$PPID" ]; then + ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \ + -c "no ipv6 route $VAR(../@) null0"; + rm /tmp/static.$PPID; + else + if [ -n "$VAR(./distance/@)" ]; then + DIST="$VAR(./distance/@)"; + fi; + ${vyatta_sbindir}/vyatta-vtysh.pl -c "configure terminal" \ + -c "ipv6 route $VAR(../@) null0 $DIST"; + fi; -- cgit v1.2.3