How can I get the password of a user in the new ASP.NET Identity system? Or how can I reset without knowing the current one (user forgot password)?
I did a little investigation and the solution that works for me was a mix of a few solutions founded in this post.
I'm basically compiling this solution and I'm posting what works for me. In my case, I'm don't want to use any token from .net core.
public async Task ResetPassword(string userId, string password)
{
var user = await _userManager.FindByIdAsync(userId);
var hashPassword= _userManager.PasswordHasher.HashPassword(user, password);
user.PasswordHash = passwordHash;
await _userManager.UpdateAsync(user);
}