CPM/SRS - winRc=2245: 'The password does not meet the password policy requirements. Check the minimum password length, password complexity and password history requirements.'
Symptom
When CPM/SRS tries to manage a Windows account, a winRc=2245 error is returned. Depending on which log is viewed, the error may look like the below:
- .Debug.Log:
- Changing password for user [<domain>\<username>] on [\\<address>] failed. Error: 2245.
- .log:
- Error in changepass to user <domain>\<username> on domain \\<address>(\\<address>).(winRc=2245) The password does not meet the password policy requirements. Check the minimum password length, password complexity and password history requirements.
- pm.log:
- Error in changepass to user <domain>\<username> on domain \\<address>(\\<address>).(winRc=2245) The password does not meet the password policy requirements. Check the minimum password length, password complexity and password history requirements.
Environment
Privileged Access Manager (PAM, self-hosted);Privilege Cloud Central Policy Manager (CPM);Secrets Rotation Service (SRS)
CPM/SRS
Windows Target
Cause
This error is generated when the CPM/SRS plugin attempts to perform a change or reconcile action against an account, local or domain-based, but the password that CPM/SRS attempts to set does not meet the password policy requirements applied to the target device. The issue can be due to a mismatch with:
- Password History
- Password Age
- Password Length
- Password Complexity
winRc stands for Windows Return Code. Windows Return Codes are generated by Windows systems. The return code shown in the CPM/SRS logs and PVWA UI is from the target Windows machine and not from CPM/SRS.
winRc=2245 Error Definition:
ERROR_PASSWORD_RESTRICTION
2245 (0x8C5)
The password does not meet the password policy requirements. Check the minimum password length, password complexity and password history requirements.
Resolution
To resolve this issue, ensure that the relevant password policy parameters set on the platform that the account object is assigned to, as well as the master policy exceptions for that platform, match, or are more stringent, than the corresponding password policies applied to the target device. Refer to the table below for the configurable password policy-related parameters in PVWA and their corresponding password policy settings in Windows:
| Name of Parameter/Policy in PVWA | Location in PVWA | Name of Comparable Windows Policy | Notes |
| EnforcePasswordVersionsHistory | Edit the Platform -> Automatic Password Management (APM) -> Password Change | Enforce password history | |
| Require password change every X days | Policies -> Policy by Platform -> select relevant platform -> Password Management |
Maximum password age Minimum password age |
-Lowest possible value for policy exception is one day. -Manual password rotations supersede this policy. |
| PasswordLength | Platform, APM -> Generate Password | Minimum password length | |
| MinUpperCase, MinLowerCase, MinDigit, MinSpecial | Platform, APM -> Generate Password | Password must meet complexity requirements | |
| PasswordForbiddenChars | Platform, APM -> Generate Password | NA | -Not generally applicable to Windows password policies. |
| PasswordEffectiveLength | Platform, APM -> Generate Password | NA | -Not generally applicable to Windows password policies. |
| PreventSameCharPerPrevPassPosition | Platform, APM -> Generate Password | NA | -Not generally applicable to Windows password policies. |
| PreventRepeatingCharacters | Platform, APM -> Generate Password | NA | -Not generally applicable to Windows password policies. |
Resources:
How does CPM Manage Windows Accounts Passwords
Windows System Error Codes
Windows Network Management Error Codes
Windows Routing and Remote Access Error Codes
Windows Sockets Error Codes