password-control { aging | composition | history | length } enable
Use password-control { aging | composition | history | length } enable to enable the password expiration, composition restriction, history, or minimum length restriction feature.
Use undo password-control { aging | composition | history | length } enable to disable a password control feature.
Syntax
password-control { aging | composition | history | length } enable
undo password-control { aging | composition | history | length } enable
Default
The password control features (aging, composition, history, and length) are all enabled.
Views
System view
Predefined user roles
network-admin
mdc-admin
Parameters
aging: Enables the password expiration feature.
composition: Enables the password composition restriction feature.
history: Enables the password history feature.
length: Enables the minimum password length restriction feature.
Usage guidelines
For a specific password control feature to take effect, make sure the global password control and the specific password control feature are both enabled. For example, if the global password control and the minimum length restriction feature are not enabled, the password-control length command does not take effect.
The system stops recording history passwords after you execute the undo password-control history enable command, but it does not delete the prior records.
If the global password control feature is enabled but the minimum password length restriction feature is disabled, the following rules apply:
In non-FIPS mode, a password must contain a minimum of 4 characters and a minimum of 4 characters must be different.
In FIPS mode, a password must contain a minimum of 15 characters and a minimum of 4 characters must be different.
Examples
# Enable the password control feature globally.
<Sysname> system-view [Sysname] password-control enable
# Enable the password composition restriction feature.
[Sysname] password-control composition enable
# Enable the password expiration feature.
[Sysname] password-control aging enable
# Enable the minimum password length restriction feature.
[Sysname] password-control length enable
# Enable the password history feature.
[Sysname] password-control history enable
Related commands
display password-control
password-control enable