mirror of
https://github.com/usnistgov/macos_security.git
synced 2026-02-03 14:03:24 +00:00
pwpolicy_account_lockout_enforce issues with Sonoma #147
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @robertgendler on GitHub.
Discussed in https://github.com/usnistgov/macos_security/discussions/310
Originally posted by danieldotweinert September 28, 2023
Currently having this issue with the Sonoma compliance script...as you can see the output show it as 'yes' but includes a line break and extra yes which is causing the rule to fail and make the device non compliant. Any ideas?
Thu Sep 28 19:58:14 UTC 2023 pwpolicy_account_lockout_enforce failed (Result: yes
yes, Expected: {string: yes})
@danieldotweinert commented on GitHub:
@robertgendler commented on GitHub:
So I'm not able to reproduce this.
I created a baseline file with just the 1 rule. And it appears when I run with --check it spits it out correctly.
Are you setting an ODV value? Can you copy/paste your custom rule?
@danieldotweinert commented on GitHub:
Config Profile settings:

@brodjieski commented on GitHub:
Can you provide the output of
sudo /usr/bin/pwpolicy -getaccountpolicies@danieldotweinert commented on GitHub:
Output from jamf logs:
@brodjieski commented on GitHub:
When password policies are applied with a profile, they get written to pwpolicy, however when you remove a profile, it doesn't clean itself up. So depending on how you applied or removed profiles, old policies may still be in the mix.
@danieldotweinert commented on GitHub:
Thanks @brodjieski and @robertgendler! That resolved my issue. Any idea why it populated twice?
@brodjieski commented on GitHub:
Your password policy has
policyAttributeMaximumFailedAuthenticationsdefined twice. This is what is causing the issue. Try clearing your password policy and re-applying.You can clear them by
sudo pwpolicy -clearaccountpolicies.@robertgendler commented on GitHub:
Closing, since it's resolved.