You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[YANG] Add support for Password Hardening (#10322)
- Why I did it
Yang Model about password hardening feature, the sonic CLI of this feature was autogenerated from this Yang model
- How I did it
Create new Yang model in src/sonic-yang-models/yang-models/sonic-passwh.yang.
- How to verify it
There are unitests(yang test) in this P.R covering all the passwords policies with good and bad values cases.
Or is possible manually using the config/show password commands that were autogenerated from this Yang model. (this CLI code added in sonic-utilities)
Copy file name to clipboardExpand all lines: src/sonic-yang-models/doc/Configuration.md
+35
Original file line number
Diff line number
Diff line change
@@ -51,6 +51,7 @@ Table of Contents
51
51
* [VLAN_MEMBER](#vlan_member)
52
52
* [Virtual router](#virtual-router)
53
53
* [WRED_PROFILE](#wred_profile)
54
+
* [PASSWORD_HARDENING](#password_hardening)
54
55
*[For Developers](#for-developers)
55
56
*[Generating Application Config by Jinja2 Template](#generating-application-config-by-jinja2-template)
56
57
*[Incremental Configuration by Subscribing to ConfigDB](#incremental-configuration-by-subscribing-to-configdb)
@@ -1506,6 +1507,40 @@ The packet action could be:
1506
1507
}
1507
1508
}
1508
1509
```
1510
+
### PASSWORD_HARDENING
1511
+
1512
+
Password Hardening, a user password is the key credential used in order to verify the user accessing the switch and acts as the first line of defense in regards to securing the switch. PASSWORD_HARDENING - support the enforce strong policies.
1513
+
1514
+
- state - Enable/Disable password hardening feature
1515
+
- len_min - The minimum length of the PW should be subject to a user change.
1516
+
- expiration - PW Age Change Once a PW change takes place - the DB record for said PW is updated with the new PW value and a fresh new age (=0).
1517
+
- expiration_warning - The switch will provide a warning for PW change before and (this is to allow a sufficient warning for upgrading the PW which might be relevant to numerous switches).
1518
+
- history_cnt - remember last passwords, and reject to use the old passw
1519
+
- reject_user_passw_match - reject to set same username and passw
1520
+
- PW classes - are the type of characters the user is required to enter when setting/updating a PW.
1521
+
There are 4 classes
1522
+
- lower_class - Small characters - a-z
1523
+
- upper_class - Big characters - A-Z
1524
+
- digits_class -Numbers - 0-9
1525
+
- special_class - Special Characters `~!@#$%^&*()-_+=|[{}];:',<.>/? and white space
0 commit comments