Generate temporary URL to reset password

前端 未结 9 745
隐瞒了意图╮
隐瞒了意图╮ 2021-01-30 02:08

I am looking to implement a Forgot Password feature on my website. I like the option where an email containing a temporary one-time use URL that expires after some time is sent

9条回答
  •  清歌不尽
    2021-01-30 02:29

    @Alex

    You can also use System.Security.Cryptography classes in .NET for the hash algorithms. For example:

    using System.Security.Cryptography;
    ...
    var hash = SHA256CryptoServiceProvider.Create().ComputeHash(myTokenToHash);
    ...
    

提交回复
热议问题