- 1 year ago
Windows 10 - Changing User Password Remotely WITHOUT Losing Credential Manager
Changing a user's password remotely on Windows 10 without losing the Credential Manager can be achieved using PowerShell remoting. Here's a step-by-step guide:
Open a PowerShell session with administrative privileges on your local machine.
Enable PowerShell remoting on the remote machine by running the following command:
powershellEnable-PSRemoting -Force
On the remote machine, open a PowerShell session with administrative privileges.
Allow incoming remote connections by running the following command:
powershellSet-Item WSMan:\localhost\Client\TrustedHosts -Value <local machine IP address> -Force
Replace
<local machine IP address>
with the IP address of your local machine.Restart the WinRM service on the remote machine to apply the changes:
powershellRestart-Service WinRM
From your local machine, establish a remote PowerShell session with the remote machine using the following command:
powershellEnter-PSSession -ComputerName <remote machine IP address> -Credential (Get-Credential)
Replace
<remote machine IP address>
with the IP address of the remote machine.Enter the credentials of an administrative user on the remote machine when prompted.
Now, you can change the user's password remotely by running the following command:
powershellSet-LocalUser -Name <username> -Password (ConvertTo-SecureString -AsPlainText "<new password>" -Force)
Replace
<username>
with the username of the user whose password you want to change, and<new password>
with the desired new password.Close the remote PowerShell session by running the
Exit-PSSession
command.
By following these steps, you can change a user's password remotely on Windows 10 without losing the Credential Manager data. Make sure to replace the placeholders with the appropriate values for your specific scenario.