Upgrade to Sitecore 10 locked users

Due to a change in cryptography, an upgrade to Sitecore 10 may lock some of your users, making their passwords to stop working.

The easiest way to solve this would be create a Powershell Script to reset their password

I had to create a small powershell to perform this task

The script below will reset the users within domain “sitecore” and print their result on the screen

Write-Host "Starting script for reset all the users under sitecore domain"
[int]$passlength = 8
[string]$pass
$users = Get-User -Filter "sitecore\*"
$i = 1;
ForEach ($item in $users) {

        for($i=0; $i -lt $passlength; $i++)
		{
           $pass += [char](Get-Random -Minimum 33 -Maximum 126)
        }

        Set-UserPassword -Identity $item.LocalName -NewPassword $pass -Reset
        Write-Host "Username,"$item.LocalName","$item.Name",Password,"$pass
        $pass = ""
}