diff options
author | Christian Poessinger <christian@poessinger.com> | 2020-02-05 19:30:33 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2020-02-05 19:30:33 +0100 |
commit | 0840e9783053522cdec2826aa200c80921b6e7b8 (patch) | |
tree | 9d2a78682637d5ac2bc451041f04d2eb13291c4d /templates/system | |
parent | 28a6a655774fa997cc58b95dede946e07fb9719a (diff) | |
download | vyatta-cfg-system-0840e9783053522cdec2826aa200c80921b6e7b8.tar.gz vyatta-cfg-system-0840e9783053522cdec2826aa200c80921b6e7b8.zip |
login: T1990: Migrate "system login" to XML/Python representation
Diffstat (limited to 'templates/system')
19 files changed, 0 insertions, 115 deletions
diff --git a/templates/system/login/node.def b/templates/system/login/node.def deleted file mode 100644 index 09255a76..00000000 --- a/templates/system/login/node.def +++ /dev/null @@ -1,4 +0,0 @@ -priority: 400 -help: User login -delete: echo 'All login methods can not be deleted' 1>&2; exit 1 -end: sudo /opt/vyatta/sbin/vyatta_update_login.pl diff --git a/templates/system/login/radius/node.def b/templates/system/login/radius/node.def deleted file mode 100644 index 86baaabe..00000000 --- a/templates/system/login/radius/node.def +++ /dev/null @@ -1 +0,0 @@ -help: RADIUS specific configuration diff --git a/templates/system/login/radius/server/node.def b/templates/system/login/radius/server/node.def deleted file mode 100644 index ba47c5d7..00000000 --- a/templates/system/login/radius/server/node.def +++ /dev/null @@ -1,6 +0,0 @@ -tag: -type: ipv4 -help: Radius server authentication -commit:expression: $VAR(port) != "" && $VAR(key) != "" - && $VAR(timeout) != "" - ; "Port, Key, and Timeout must be specified for RADIUS" diff --git a/templates/system/login/radius/server/node.tag/key/node.def b/templates/system/login/radius/server/node.tag/key/node.def deleted file mode 100644 index 90420518..00000000 --- a/templates/system/login/radius/server/node.tag/key/node.def +++ /dev/null @@ -1,2 +0,0 @@ -type: txt -help: Secret for radius access [REQUIRED] diff --git a/templates/system/login/radius/server/node.tag/port/node.def b/templates/system/login/radius/server/node.tag/port/node.def deleted file mode 100644 index d3869f55..00000000 --- a/templates/system/login/radius/server/node.tag/port/node.def +++ /dev/null @@ -1,8 +0,0 @@ -type: u32 -help: Radius port [default: 1812] -default: 1812 - -val_help: u32:1-65535; Numeric IP port -syntax:expression: $VAR(@) > 0 && $VAR(@) <= 65535 ; \ - "Port number must be in range 1 to 65535" - diff --git a/templates/system/login/radius/server/node.tag/timeout/node.def b/templates/system/login/radius/server/node.tag/timeout/node.def deleted file mode 100644 index a4637981..00000000 --- a/templates/system/login/radius/server/node.tag/timeout/node.def +++ /dev/null @@ -1,5 +0,0 @@ -type: u32 -help: Timeout for radius session in seconds [default: 2] -default: 2 -syntax:expression: $VAR(@) > 0 && $VAR(@) <= 30 \ - ; "Timeout must be between 1 and 30 seconds" diff --git a/templates/system/login/radius/source-address/node.def b/templates/system/login/radius/source-address/node.def deleted file mode 100644 index 546bfaa3..00000000 --- a/templates/system/login/radius/source-address/node.def +++ /dev/null @@ -1,2 +0,0 @@ -type: ipv4 -help: Local RADIUS client address from which packets are sent diff --git a/templates/system/login/user/node.def b/templates/system/login/user/node.def deleted file mode 100644 index 4dffb9b7..00000000 --- a/templates/system/login/user/node.def +++ /dev/null @@ -1,14 +0,0 @@ -tag: -type: txt -help: User account information - -syntax:expression: exec "/opt/vyatta/sbin/vyatta_check_username.pl $VAR(@)" -syntax:expression: exec "${vyos_libexec_dir}/validate-value.py --regex \'^[a-zA-Z0-9\-_\.]{1,100}\' --value \'$VAR(@)\'"; "illegal characters in username or longer than 100 chars" - -commit:expression: $VAR(@) == "" || - $VAR(authentication/plaintext-password) != "" || - $VAR(authentication/plaintext-password/@) = "" - -commit:expression: $VAR(@) == "" || - $VAR(authentication/encrypted-password) != "" || - $VAR(authentication/encrypted-password/@) = "!" 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 deleted file mode 100644 index 29ad14a8..00000000 --- a/templates/system/login/user/node.tag/authentication/encrypted-password/node.def +++ /dev/null @@ -1,11 +0,0 @@ -type: txt -help: Encrypted password -# Allow * or ! to disable account -# DES format password (13 characters) -# MD5 format ($1) and SHA format passwords -syntax:expression: ($VAR(@) == "*" || $VAR(@) == "!" \ - || ( pattern $VAR(@) "^[a-zA-Z0-9\.\/]{13}$" ) \ - || ( pattern $VAR(@) "^\\$1\\$[a-zA-Z0-9\./]*\\$[a-zA-Z0-9\./]{22}$" ) \ - || ( pattern $VAR(@) "^\\$5\\$[a-zA-Z0-9\./]*\\$[a-zA-Z0-9\./]{43}$" ) \ - || ( pattern $VAR(@) "^\\$6\\$[a-zA-Z0-9\./]*\\$[a-zA-Z0-9\./]{86}$" )) \ - ; "Not a valid encrypted password for user $VAR(../../@)" diff --git a/templates/system/login/user/node.tag/authentication/node.def b/templates/system/login/user/node.tag/authentication/node.def deleted file mode 100644 index 4306d008..00000000 --- a/templates/system/login/user/node.tag/authentication/node.def +++ /dev/null @@ -1 +0,0 @@ -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 deleted file mode 100644 index 407f49b5..00000000 --- a/templates/system/login/user/node.tag/authentication/plaintext-password/node.def +++ /dev/null @@ -1,9 +0,0 @@ -type: txt -help: Plaintext password for encryption -# if plaintext is empty, assume this is left-over from blanking the plaintext -# and do nothing. - -update:expression: $VAR(@) == "" \ -|| ($VAR(../encrypted-password/@) \ - = `/usr/bin/mkpasswd --method=sha-512 '$VAR(@)' | tr -d \\\\n` \ - && $VAR(@) = "") diff --git a/templates/system/login/user/node.tag/authentication/public-keys/node.def b/templates/system/login/user/node.tag/authentication/public-keys/node.def deleted file mode 100644 index 245e7197..00000000 --- a/templates/system/login/user/node.tag/authentication/public-keys/node.def +++ /dev/null @@ -1,9 +0,0 @@ -tag: -type: txt -help: Remote access public keys -val_help: Key identifier used by ssh-keygen (usually of form user@host) - -commit:expression: $VAR(./type/) != "" ; \ - "Must configure public key type for $VAR(@)" -commit:expression: $VAR(./key/) != "" ; \ - "Must configure public key value for $VAR(@)" diff --git a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/key/node.def b/templates/system/login/user/node.tag/authentication/public-keys/node.tag/key/node.def deleted file mode 100644 index 6ca70736..00000000 --- a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/key/node.def +++ /dev/null @@ -1,9 +0,0 @@ -type: txt -help: Public key value (base64-encoded) -syntax:expression: pattern $VAR(@) "^[0-9A-Za-z+/=]*$" ; \ - "Invalid public key character not base-64" - -comp_help: The key is usually several hundred bytes long (because of the size -of the public key encoding). Use the loadkey tool to input key from -a URL or file. - diff --git a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/options/node.def b/templates/system/login/user/node.tag/authentication/public-keys/node.tag/options/node.def deleted file mode 100644 index 2677594b..00000000 --- a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/options/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: txt -help: Additional public key options - diff --git a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/type/node.def b/templates/system/login/user/node.tag/authentication/public-keys/node.tag/type/node.def deleted file mode 100644 index bf789e06..00000000 --- a/templates/system/login/user/node.tag/authentication/public-keys/node.tag/type/node.def +++ /dev/null @@ -1,4 +0,0 @@ -type: txt -help: Public key type -allowed: echo "ssh-dss ssh-rsa ecdsa-sha2-nistp256 ecdsa-sha2-nistp384 ecdsa-sha2-nistp521 ssh-ed25519" -syntax:expression: $VAR(@) in "ssh-rsa", "ssh-dss", "ecdsa-sha2-nistp256", "ecdsa-sha2-nistp384", "ecdsa-sha2-nistp521", "ssh-ed25519"; "Unknown key type" diff --git a/templates/system/login/user/node.tag/full-name/node.def b/templates/system/login/user/node.tag/full-name/node.def deleted file mode 100644 index 42d9dfac..00000000 --- a/templates/system/login/user/node.tag/full-name/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: txt -help: Full name of the user (use quotes for names with spaces) -syntax:expression: pattern $VAR(@) "^[^:]*$"; "Cannot use ':' in full name" diff --git a/templates/system/login/user/node.tag/group/node.def b/templates/system/login/user/node.tag/group/node.def deleted file mode 100644 index 77d52ed8..00000000 --- a/templates/system/login/user/node.tag/group/node.def +++ /dev/null @@ -1,15 +0,0 @@ -multi: -type: txt -help: Additional group membership -val_help: <groupname>; Group name -val_help: u32:0-65535; Group ID - -syntax:expression: pattern $VAR(@) "^[a-zA-Z_][a-zA-Z0-9_-]*\\$?$" - ; "Invalid group name $VAR(@)" -syntax:expression: ! $VAR(@) in \ - "frrvty", "vyattacfg", "vyattaop", "sudo", "adm", "operator" - ; "Use configuration level to change membership of operator and admin groups" -allowed: awk -F: ' - $1 == "frrvty" || $1 == "vyattacfg" || $1 == "vyattaop" || \ - $1 == "sudo" || $1 == "adm" || $1 == "operator" { next; } - {printf "%s ", $1}' </etc/group diff --git a/templates/system/login/user/node.tag/home-directory/node.def b/templates/system/login/user/node.tag/home-directory/node.def deleted file mode 100644 index 90b62195..00000000 --- a/templates/system/login/user/node.tag/home-directory/node.def +++ /dev/null @@ -1,2 +0,0 @@ -type: txt -help: Home directory diff --git a/templates/system/login/user/node.tag/level/node.def b/templates/system/login/user/node.tag/level/node.def deleted file mode 100644 index 73b1b3c2..00000000 --- a/templates/system/login/user/node.tag/level/node.def +++ /dev/null @@ -1,7 +0,0 @@ -type: txt -help: User privilege level -default: "admin" -allowed: echo admin -syntax:expression: $VAR(@) in "admin"; "Allowed levels are \"admin\"" - -val_help: admin; Administrators |