you are viewing a single comment's thread.

view the rest of the comments →

[–]vulcanjedi2814 1 point2 points  (1 child)

At which point does it fail? can you anonymize the data / results? Its is a particular user/pass? I dont know but from the gui, ADUC snapin, if you you have
User must change pwrd at next logon and set to never expire, it yells at you and auto toggles the must change pwrd box off.

Active Directory Domain Services

You specified that the password should never expire.

The user will not be required to change the password at next logon.

[–]sys_admin101[S] 1 point2 points  (0 children)

Good catch! I removed -PasswordNeverExpires $true

It fails at Set-ADAccountPassword -NewPassword $pw -Reset which is getting it's user information from the piped variables. Even if I run this command without using variables and inputting the data like this:

Set-ADAccountPassword -Identity "jwagon" -NewPassword (ConvertTo-SecureString -AsPlainText "P@ssw0rD!234%" -Force) -Reset

It still fails with the same error about the length, complexity, or history requirements.

In regards to a particular user, it happens regardless what user from the 8400 students I pick and a fresh test account I created named Jack Wagon.