Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/sonic-yang-models/tests/yang_model_tests/tests/aaa.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@
"desc": "Configure a wrong type in AAA table.",
"eStrKey": "InvalidValue"
},
"AAA_TEST_WRONG_LOGIN": {
"desc": "Configure a wrong type in AAA table.",
"eStr": ["Invalid login choice"]
},
"AAA_TEST_WRONG_FAILTHROUGH": {
"desc": "Configure a wrong failthrough in AAA table.",
"eStrKey": "Pattern",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,16 @@
}
},

"AAA_TEST_WRONG_LOGIN": {
"sonic-system-aaa:sonic-system-aaa": {
"sonic-system-aaa:AAA": {
"AAA_LIST": [{
"login": "locallll"
}]
}
}
},

"AAA_TEST_WRONG_FAILTHROUGH": {
"sonic-system-aaa:sonic-system-aaa": {
"sonic-system-aaa:AAA": {
Expand Down
8 changes: 6 additions & 2 deletions src/sonic-yang-models/yang-models/sonic-system-aaa.yang
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,12 @@ module sonic-system-aaa {
}

leaf login {
type string;
description "AAA authentication/authorization/accounting methods - local/tacacs+/disable";
type string {
pattern '((tacacs\+|local|radius|default),)*(tacacs\+|local|radius|default)' {
error-message "Invalid login choice";
}
}
description "AAA authentication/authorization/accounting methods - radius/tacacs+/local/default";
default "local";
}

Expand Down