APPL-14-003080 - The macOS system must disable accounts after 35 days of inactivity.

Information

The macOS must be configured to disable accounts after 35 days of inactivity.

This rule prevents malicious users from making use of unused accounts to gain access to the system while avoiding detection.

Solution

Configure the macOS system to disable accounts after 35 days of inactivity with the following command:

This setting may be enforced using local policy or by a directory service.

To set local policy to disable an inactive user after 35 days, edit the current password policy to contain the following <dict> within the "policyCategoryAuthentication":

[source,xml]
----
<dict>
<key>policyContent</key>
<string>policyAttributeLastAuthenticationTime > policyAttributeCurrentTime - (policyAttributeInactiveDays * 24 * 60 * 60)</string>
<key>policyIdentifier</key>
<string>Inactive Account</string>
<key>policyParameters</key>
<dict>
<key>policyAttributeInactiveDays</key>
<integer>35</integer>
</dict>
</dict>
----
After saving the file and exiting to the command prompt, run the following command to load the new policy file, substituting the path to the file in place of "$pwpolicy_file".

[source,bash]
----
/usr/bin/pwpolicy setaccountpolicies $pwpolicy_file
----
Note: Refer to the password policy supplemental on more information on how to implement password policies on macOS.

See Also

https://dl.dod.cyber.mil/wp-content/uploads/stigs/zip/U_Apple_macOS_14_V2R2_STIG.zip

Item Details

Category: IDENTIFICATION AND AUTHENTICATION

References: 800-53|IA-4e., CAT|II, CCI|CCI-000795, CCI|CCI-003627, CCI|CCI-003628, Rule-ID|SV-259552r1009605_rule, STIG-ID|APPL-14-003080, Vuln-ID|V-259552

Plugin: Unix

Control ID: d988de20b8d548ca25129d59eb1d1deea14faaa56f0b5bf2900fe1bbc69f5423