Pregunta

I am creating a web application and I want to have the capability of resetting passwords in two different ways. For those with an internet connection I am simply using an SMTP server and sending an email. This is working fine.

For those without an internet connection I want to have a simple local password reset. I was attempting to do this local password reset by creating a form very similar to that of the built-in password recovery class. I first ask for the user's username, and they are then prompted to answer their security question. After answering the question I was going to redirect the user to the change password page. My problem is that I was hoping to use the built-in asp.NET user security question, but I can't seem to find a way to access the answer to the question. Furthermore if someone can help access the question's answer, I was wondering if there was an authentication for this, or if I should do a simple string comparison between the answer typed in and the answer stored to the user.

¿Fue útil?

Solución

Protected Sub PasswordRecovery1_SendingMail(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.MailMessageEventArgs) Handles PasswordRecovery1.SendingMail

    e.Cancel = True;
    PasswordRecovery1.SuccessText = e.Message.Body;

Link: http://forums.asp.net/t/1138927.aspx/2/10

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top