summaryrefslogtreecommitdiff
path: root/templates/system/login
diff options
context:
space:
mode:
authorAn-Cheng Huang <ancheng@vyatta.com>2008-01-31 07:59:02 -0800
committerAn-Cheng Huang <ancheng@vyatta.com>2008-01-31 07:59:02 -0800
commit622bbf801bd435a3848c669ff2c0e9090cd2bb4e (patch)
tree328d04410e8fed64e6a8b25abdf58f199d916c2d /templates/system/login
parentc2c002021eab0adff7e4d268535170658a1b0c6c (diff)
downloadvyatta-cfg-quagga-622bbf801bd435a3848c669ff2c0e9090cd2bb4e.tar.gz
vyatta-cfg-quagga-622bbf801bd435a3848c669ff2c0e9090cd2bb4e.zip
convert templates to new syntax
Diffstat (limited to 'templates/system/login')
-rw-r--r--templates/system/login/node.def4
-rw-r--r--templates/system/login/radius-server/node.def12
-rw-r--r--templates/system/login/radius-server/node.tag/port/node.def4
-rw-r--r--templates/system/login/radius-server/node.tag/secret/node.def2
-rw-r--r--templates/system/login/radius-server/node.tag/timeout/node.def2
-rw-r--r--templates/system/login/user/node.def22
-rw-r--r--templates/system/login/user/node.tag/authentication/encrypted-password/node.def2
-rw-r--r--templates/system/login/user/node.tag/authentication/node.def2
-rw-r--r--templates/system/login/user/node.tag/authentication/plaintext-password/node.def10
-rw-r--r--templates/system/login/user/node.tag/full-name/node.def2
-rw-r--r--templates/system/login/user/node.tag/level/node.def10
11 files changed, 36 insertions, 36 deletions
diff --git a/templates/system/login/node.def b/templates/system/login/node.def
index bde75b4c..ca2da1b3 100644
--- a/templates/system/login/node.def
+++ b/templates/system/login/node.def
@@ -1,3 +1,3 @@
-help: "Configure user access"
-delete: "echo User root cannot be deleted 1>&2 && exit 1"
+help: Configure user access
+delete:expression: "echo User root cannot be deleted 1>&2 && exit 1"
diff --git a/templates/system/login/radius-server/node.def b/templates/system/login/radius-server/node.def
index 0f4ffbfe..6d87890c 100644
--- a/templates/system/login/radius-server/node.def
+++ b/templates/system/login/radius-server/node.def
@@ -1,10 +1,10 @@
tag:
type: ipv4
-help: "Radius server authentication configuration"
+help: Radius server authentication configuration
# need mandatory secret. also need port & timeout (default values?)
-update: "sudo sh -c \"touch /etc/raddb/server && \
-sed -i '/$(@)/d' /etc/raddb/server && \
-echo \\\"$(@):$(port/@)\t$(secret/@)\t$(timeout/@)\\\" \
+update:expression: "sudo sh -c \"touch /etc/raddb/server && \
+sed -i '/$VAR(@)/d' /etc/raddb/server && \
+echo \\\"$VAR(@):$VAR(port/@)\t$VAR(secret/@)\t$VAR(timeout/@)\\\" \
>> /etc/raddb/server\" "
-delete: "sudo sh -c \"touch /etc/raddb/server && \
-sed -i '/$(@)/d' /etc/raddb/server\" "
+delete:expression: "sudo sh -c \"touch /etc/raddb/server && \
+sed -i '/$VAR(@)/d' /etc/raddb/server\" "
diff --git a/templates/system/login/radius-server/node.tag/port/node.def b/templates/system/login/radius-server/node.tag/port/node.def
index 8c856e78..002bc8a0 100644
--- a/templates/system/login/radius-server/node.tag/port/node.def
+++ b/templates/system/login/radius-server/node.tag/port/node.def
@@ -1,4 +1,4 @@
type: u32
-help: "Configure radius port"
-syntax: ($(@) > 0 && $(@) < 65536) ; "port must be between 1 and 65535"
+help: Configure radius port
+syntax:expression: ($VAR(@) > 0 && $VAR(@) < 65536) ; "port must be between 1 and 65535"
default: 1812
diff --git a/templates/system/login/radius-server/node.tag/secret/node.def b/templates/system/login/radius-server/node.tag/secret/node.def
index eb08eca3..71176843 100644
--- a/templates/system/login/radius-server/node.tag/secret/node.def
+++ b/templates/system/login/radius-server/node.tag/secret/node.def
@@ -1,2 +1,2 @@
type: txt
-help: "Secret for radius access"
+help: Secret for radius access
diff --git a/templates/system/login/radius-server/node.tag/timeout/node.def b/templates/system/login/radius-server/node.tag/timeout/node.def
index 84bb4424..23a964a6 100644
--- a/templates/system/login/radius-server/node.tag/timeout/node.def
+++ b/templates/system/login/radius-server/node.tag/timeout/node.def
@@ -1,3 +1,3 @@
type: u32
-help: "Timeout for radius session"
+help: Timeout for radius session
default: 2
diff --git a/templates/system/login/user/node.def b/templates/system/login/user/node.def
index a04e990f..6c5a5c2a 100644
--- a/templates/system/login/user/node.def
+++ b/templates/system/login/user/node.def
@@ -1,23 +1,23 @@
tag:
type: txt
-help: "User account information"
-syntax: pattern $(@) "^[a-zA-Z_][a-zA-Z0-9_-]*\\$?$" ; "invalid user name $(@)"
+help: User account information
+syntax:expression: pattern $VAR(@) "^[a-zA-Z_][a-zA-Z0-9_-]*\\$?$" ; "invalid user name $VAR(@)"
# line continuation and $() expansion are done by cli, not sh.
# need mandatory encrypted password.
-end: "if [ -d /tmp/vyatta-delete-system-login-user-$(@).\\\$PPID ]; \
-then rm -rf /tmp/vyatta-delete-system-login-user-$(@).\\\$PPID && exit 0; \
+end:expression: "if [ -d /tmp/vyatta-delete-system-login-user-$VAR(@).$PPID ]; \
+then rm -rf /tmp/vyatta-delete-system-login-user-$VAR(@).$PPID && exit 0; \
fi && \
sudo /opt/vyatta/sbin/vyatta_update_login_user.pl \
- '$(@)' '$(full-name/@)' '$(authentication/encrypted-password/@)' \
- '$(level/@)'"
-delete: "if [ x$(@) == x ]; then exit 1; fi && \
-if [ x$(@) == xroot ]; then \
+ '$VAR(@)' '$VAR(full-name/@)' '$VAR(authentication/encrypted-password/@)' \
+ '$VAR(level/@)'"
+delete:expression: "if [ x$VAR(@) == x ]; then exit 1; fi && \
+if [ x$VAR(@) == xroot ]; then \
echo Cannot delete user \"root\" 1>&2 && exit 2; \
fi && \
-if mkdir /tmp/vyatta-delete-system-login-user-$(@).\\\$PPID >& /dev/null; \
+if mkdir /tmp/vyatta-delete-system-login-user-$VAR(@).$PPID >& /dev/null; \
then \
- if ! sudo /opt/vyatta/sbin/vyatta_update_login_user.pl -d '$(@)'; then \
- rm -rf /tmp/vyatta-delete-system-login-user-$(@).\\\$PPID; \
+ if ! sudo /opt/vyatta/sbin/vyatta_update_login_user.pl -d '$VAR(@)'; then \
+ rm -rf /tmp/vyatta-delete-system-login-user-$VAR(@).$PPID; \
exit 1; \
fi; \
else \
diff --git a/templates/system/login/user/node.tag/authentication/encrypted-password/node.def b/templates/system/login/user/node.tag/authentication/encrypted-password/node.def
index 33a87f59..cd800ce4 100644
--- a/templates/system/login/user/node.tag/authentication/encrypted-password/node.def
+++ b/templates/system/login/user/node.tag/authentication/encrypted-password/node.def
@@ -1,2 +1,2 @@
type: txt
-help: "Configure encrypted password"
+help: Configure encrypted password
diff --git a/templates/system/login/user/node.tag/authentication/node.def b/templates/system/login/user/node.tag/authentication/node.def
index 8b0f3125..4306d008 100644
--- a/templates/system/login/user/node.tag/authentication/node.def
+++ b/templates/system/login/user/node.tag/authentication/node.def
@@ -1 +1 @@
-help: "Authentication password"
+help: Authentication password
diff --git a/templates/system/login/user/node.tag/authentication/plaintext-password/node.def b/templates/system/login/user/node.tag/authentication/plaintext-password/node.def
index 0e2bd7a5..1ac3c203 100644
--- a/templates/system/login/user/node.tag/authentication/plaintext-password/node.def
+++ b/templates/system/login/user/node.tag/authentication/plaintext-password/node.def
@@ -1,10 +1,10 @@
type: txt
-help: "Configure plaintext password for encryption"
+help: Configure plaintext password for encryption
# if plaintext is empty, assume this is left-over from blanking the plaintext
# and do nothing. to set password to empty, user needs to set the
# "encrypted-password" to an empty string (which actually allows login without
# password).
-update: $(@) == "" \
-|| ($(../encrypted-password/@) \
- = `/usr/bin/mkpasswd -H md5 '$(@)' | tr -d \\\\n` \
- && $(@) = "")
+update:expression: $VAR(@) == "" \
+|| ($VAR(../encrypted-password/@) \
+ = `/usr/bin/mkpasswd -H md5 '$VAR(@)' | tr -d \\\\n` \
+ && $VAR(@) = "")
diff --git a/templates/system/login/user/node.tag/full-name/node.def b/templates/system/login/user/node.tag/full-name/node.def
index 86b7c8d4..f9e6149a 100644
--- a/templates/system/login/user/node.tag/full-name/node.def
+++ b/templates/system/login/user/node.tag/full-name/node.def
@@ -1,2 +1,2 @@
type: txt
-help: "Full name of the user (use quotes for names with spaces)"
+help: Full name of the user (use quotes for names with spaces)
diff --git a/templates/system/login/user/node.tag/level/node.def b/templates/system/login/user/node.tag/level/node.def
index 30ac731c..66561e12 100644
--- a/templates/system/login/user/node.tag/level/node.def
+++ b/templates/system/login/user/node.tag/level/node.def
@@ -1,7 +1,7 @@
type: txt
-help: "User privilege level"
+help: User privilege level
default: "admin"
-syntax: $(@) in "admin", "users"; "Allowed levels are \"admin\" and \"users\""
-#comp_help:Possible completions:
-# admin\t\tAdministrators
-# users\t\tNormal users
+syntax:expression: $VAR(@) in "admin", "users"; "Allowed levels are \"admin\" and \"users\""
+comp_help:Possible completions:
+ admin\t\tAdministrators
+ users\t\tNormal users