I am following the tutortial for .Net core Account and password recovery and I am not sure how things work. The tutorial says to add the email service in startup.cs then everything just started to work. I have no idea where the forgot password page is located, it not with the other pages, I checked hidden files and the actual directory it self (see image), yet I am being redirected there from the reset password link. I have no idea how the email service is being called yet I can set a break point and see that it is being hit with the correct data. I can see the sql query used to get the user information. Is this functionality managed by core identity?
I have no idea where the forgot password page is located, it not with the other pages
You need Scaffold Identity in your ASP.NET Core project.
I have no idea how the email service is being called yet I can set a break point and see that it is being hit with the correct data.
Is this functionality managed by core identity?
IEmailSender is in the package ASP.NET Core Identity.UI, with the default implementation injected in DI that doesn't do anything.
I will explain in detail below how to send an email to reset the password. You can read the process of resetting the password first to the last.
In other words, you need to Implement IEmailSender.
In the link you gave, it has been given in detail how to implement IEmailSender.
In the example, SendGrid email provider is used. You can also choose other email providers.
{
... ...
"AllowedHosts": "*",
"SendGridUser": "xxxx",
"SendGridKey": "xxxxx"
}
The process of resetting the password can be briefly summarized as follows:
Result