summaryrefslogtreecommitdiff
path: root/interface-templates/ip/rip/authentication/md5
diff options
context:
space:
mode:
Diffstat (limited to 'interface-templates/ip/rip/authentication/md5')
-rw-r--r--interface-templates/ip/rip/authentication/md5/node.def8
-rw-r--r--interface-templates/ip/rip/authentication/md5/node.tag/node.def1
-rw-r--r--interface-templates/ip/rip/authentication/md5/node.tag/password/node.def19
3 files changed, 28 insertions, 0 deletions
diff --git a/interface-templates/ip/rip/authentication/md5/node.def b/interface-templates/ip/rip/authentication/md5/node.def
new file mode 100644
index 00000000..8d165fe6
--- /dev/null
+++ b/interface-templates/ip/rip/authentication/md5/node.def
@@ -0,0 +1,8 @@
+tag:
+type: u32
+help: Set MD5 authentication key ID
+syntax:expression: $VAR(@) >= 1 && $VAR(@) <= 255; \
+ "ID must be between 1 and 255"
+
+commit:expression: $VAR(../plaintext-password/) == "" ; \
+ "plaintext-password already set"
diff --git a/interface-templates/ip/rip/authentication/md5/node.tag/node.def b/interface-templates/ip/rip/authentication/md5/node.tag/node.def
new file mode 100644
index 00000000..488acd8c
--- /dev/null
+++ b/interface-templates/ip/rip/authentication/md5/node.tag/node.def
@@ -0,0 +1 @@
+help: Set authentication password
diff --git a/interface-templates/ip/rip/authentication/md5/node.tag/password/node.def b/interface-templates/ip/rip/authentication/md5/node.tag/password/node.def
new file mode 100644
index 00000000..1d675b0b
--- /dev/null
+++ b/interface-templates/ip/rip/authentication/md5/node.tag/password/node.def
@@ -0,0 +1,19 @@
+type: txt
+help: Set authentication password
+syntax:expression: pattern $VAR(@) "^[^[:space:]]{1,16}" ; "MD5 key must be 16 characters or less"
+
+update:vyatta-vtysh \
+ -c "configure terminal" -c "interface $IFNAME" \
+ -c "ip rip authentication mode md5" \
+ -c "ip rip authentication key-chain $IFNAME-rip" \
+ -c "key chain $IFNAME-rip" -c "key $VAR(../@)" \
+ -c "key-string $VAR(@)"
+
+delete:vyatta-vtysh --noerror \
+ -c "configure terminal" -c "interface $IFNAME" \
+ -c "no ip rip authentication mode md5" \
+ -c "no ip rip authentication key-chain $IFNAME-rip" \
+ -c "no key chain $IFNAME-rip" "
+
+comp_help: possible completions:
+ <text> MD5 Key (16 characters or less)