100k views
5 votes
Powershell command to reset a user's password to a specific value and require a change at their next login?

a) Set-UserPassword -Reset -Force
b) Reset-Password -User -ChangeRequired $true
c) Change-UserPassword -NewPassword -EnforceNextLogin
d) Update-UserCredential -Password -ChangeNextLogin

User Bradheintz
by
7.7k points

1 Answer

4 votes

Final answer:

The correct powershell command to reset a user's password to a specific value and require a change at their next login is option b) Reset-Password -User -ChangeRequired $true.

Step-by-step explanation:

The correct powershell command to reset a user's password to a specific value and require a change at their next login is option b) Reset-Password -User <username> -ChangeRequired $true.

This command allows you to target a specific user and set their password to a desired value. Additionally, it includes the -ChangeRequired $true flag, which forces the user to change their password at their next login.

An example usage of this command would be:

Reset-Password -User jdoe -ChangeRequired $true

User Arjunj
by
9.0k points