0

We are using Identity Server 4 for User Login Authentication and Authorization. We have implemented ASP NET.Core Identity Password Hash in our Login and used ASPNET.Identity Password Hash in our Registration. How can we change the Registration password hash to Login Password Hash.

I have installed the ASPNET core nuget package and used the IPassword Hasher Method. I am not getting to a point how to resolve this.

4

1 回答 1

0

您不能简单地将散列值从一个密码散列器转换为另一个,除非它们当然使用完全相同的散列机制(在这种情况下,首先不需要转换)。

我在几个项目中遇到过这种情况,我们更改了密码哈希机制,并且有效地,我们不得不向每个人发送密码重置电子邮件。在另一个项目中,这是不可行的,所以基本上我们强制用户在第一次登录时更改密码(我们使用旧的哈希器来验证他们当前的密码),然后使用新的哈希器对新密码进行哈希处理。

于 2019-06-07T12:23:49.617 回答