Passwords for new users or password changes must have a 24-hour minimum password lifetime restriction in /etc/login.defs.

STIG ID: ALMA-09-038300  |  SRG: SRG-OS-000075-GPOS-00043 |  Severity: medium |  CCI: CCI-000198 |  Vulnerability Id: V-269408

Vulnerability Discussion

Enforcing a minimum password lifetime helps to prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, then the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.

Check

Verify AlmaLinux OS 9 enforces 24 hours as the minimum password lifetime for new user accounts with the following command:

$ grep PASS_MIN_DAYS /etc/login.defs

PASS_MIN_DAYS 1

If the value of "PASS_MIN_DAYS" is less than "1", is not set, or is commented out, this is a finding.

Fix

Configure AlmaLinux OS 9 to enforce 24 hours as the minimum password lifetime.

Modify the "/etc/login.defs" file to set the "PASS_MIN_DAYS" parameter to 1 or greater:

PASS_MIN_DAYS 1