diff options
author | Bob Gilligan <gilligan@vyatta.com> | 2009-07-07 16:30:19 -0700 |
---|---|---|
committer | Bob Gilligan <gilligan@vyatta.com> | 2009-07-07 16:30:19 -0700 |
commit | 74a07cddce9662f378e3ec78a5304eccd458fba9 (patch) | |
tree | 84aea9eb061e2ce2b378bcd002f023fd78eab9f3 | |
parent | 9fbf0b12f2ad602315b60aa33e32ae4e3e3d1912 (diff) | |
download | vyatta-cfg-quagga-74a07cddce9662f378e3ec78a5304eccd458fba9.tar.gz vyatta-cfg-quagga-74a07cddce9662f378e3ec78a5304eccd458fba9.zip |
Bugfix 4546: Re-structure to avoid nested "end" field.
-rw-r--r-- | interface-templates/ip/ospf/authentication/md5/key-id/node.def | 14 | ||||
-rw-r--r-- | interface-templates/ip/ospf/authentication/md5/key-id/node.tag/md5-key/node.def | 13 |
2 files changed, 17 insertions, 10 deletions
diff --git a/interface-templates/ip/ospf/authentication/md5/key-id/node.def b/interface-templates/ip/ospf/authentication/md5/key-id/node.def index 8f6d90ca..5ff617e6 100644 --- a/interface-templates/ip/ospf/authentication/md5/key-id/node.def +++ b/interface-templates/ip/ospf/authentication/md5/key-id/node.def @@ -1,19 +1,13 @@ tag: + type: u32 + help: Set MD5 key id + syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; "ID must be between (1-255)" + commit:expression: $VAR(md5-key/) != ""; \ "Must add the md5-key for key-id $VAR(@)" -delete:touch /tmp/ospf-md5.$PPID - -end: if [ -f /tmp/ospf-md5.$PPID ]; then - vyatta-vtysh -c "configure terminal" -c "interface $IFNAME" \ - -c "no ip ospf message-digest-key $VAR(@)" - rm -f /tmp/ospf-md5.$PPID - else - vyatta-vtysh -c "configure terminal" -c "interface $IFNAME" \ - -c "ip ospf message-digest-key $VAR(@) md5 $VAR(md5-key/@)" - fi comp_help: possible completions: <1-255> Set the key id diff --git a/interface-templates/ip/ospf/authentication/md5/key-id/node.tag/md5-key/node.def b/interface-templates/ip/ospf/authentication/md5/key-id/node.tag/md5-key/node.def index b928e426..24f96906 100644 --- a/interface-templates/ip/ospf/authentication/md5/key-id/node.tag/md5-key/node.def +++ b/interface-templates/ip/ospf/authentication/md5/key-id/node.tag/md5-key/node.def @@ -1,5 +1,18 @@ type: txt + help: Set md5 key + syntax:expression: pattern $VAR(@) "^[^[:space:]]{1,16}$"; "MD5 key must be 16 characters or less" + comp_help: possible completions: <text> MD5 Key (16 characters or less) + +# If this node is created or its value changed +update: + vyatta-vtysh -c "configure terminal" -c "interface $IFNAME" \ + -c "ip ospf message-digest-key $VAR(../@) md5 $VAR(@)" + +# If this node is deleted +delete: + vyatta-vtysh -c "configure terminal" -c "interface $IFNAME" \ + -c "no ip ospf message-digest-key $VAR(../@)" |