I need to know how to change the current password setting to become more complex. My current password setting are very weak the minimum password character number is 1 which it should be at least 8 .
It possibly depends on the distribution you use, but on CentOS/RedHat, you can find the default values in
# Password aging controls: # # PASS_MAX_DAYS Maximum number of days a password may be used. # PASS_MIN_DAYS Minimum number of days allowed between password changes. # PASS_MIN_LEN Minimum acceptable password length. # PASS_WARN_AGE Number of days warning given before a password expires. # PASS_MAX_DAYS 99999 PASS_MIN_DAYS 0 PASS_MIN_LEN 5 PASS_WARN_AGE 7
and there's additional constraints you can set with PAM: I find
password requisite pam_pwquality.so try_first_pass local_users_only retry=3 authtok_type=
/etc/pam.d/system-auth, where the pam_pwquality.so does things like the "it is based on a dictionary word" check and
retry is the number of tries you get on login, but a full introduction to PAM would probably exceed the scope of an answer.