如何检查在ASP.NET成员的问题和密码是否正确,如果不使用密码 [英] How to check whether the Question and Password in ASP.NET Membership is correct or not without using Password
问题描述
我有一个ASP.net成员我需要验证的用户问题和答案。
I am having an ASP.net Membership I need to verify the User Question and Answer.
我不需要使用的密码,因为它的散列,我们无法验证它
I dont need to use Password Because its Hashed we cannot validate it
msUser的MembershipUser = Membership.GetUser(RASEL);
MembershipUser msUser = Membership.GetUser("Rasel");
谢谢,
Lalithambigai
thanks, Lalithambigai
推荐答案
询问用户的问题,并与他们的previously提供的答案对比他们的答案?
Ask the user a question and compare their answer with their previously provided answer?
然而,哈希密码不会从验证它prevent你。简单哈希用户的响应,并与存储的密码哈希比较散。需要注意的是哈希方案可能含有盐,或者初始化字符prevent字典攻击。
However, a hashed password doesn't prevent you from verifying it. Simply hash the user's response and compare the hash with the stored password hash. Note that the hashing scheme may contain salt, or initialization characters to prevent dictionary attacks.
这篇关于如何检查在ASP.NET成员的问题和密码是否正确,如果不使用密码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!