AspNetCore.Docs
AspNetCore.Docs copied to clipboard
AddDefaultIdentity , AddIdentity
When adding "configure.SignIn.RequireConfirmEmail" and changing AddDefaultIdentity to AddIdentity the Login and Register link no longer work when running the app. If I change it back to AddDefaultIdentity, I get the error "IServiceCollection does not contain a definition for AddDfaultIdentity. The code: services.AddDefaultIdentity<IdentityUser, IdentityRole>(configure => { configure.SignIn.RequireConfirmedEmail = true; }) .AddEntityFrameworkStores<ApplicationDbContext>(); Do I need to change the routes somewhere?
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
- ID: fe1bea60-d173-f6d2-3559-b147699e295a
- Version Independent ID: 98e7aacb-2a01-d581-9b03-bfef2893163e
- Content: Account confirmation and password recovery in ASP.NET Core
- Content Source: aspnetcore/security/authentication/accconfirm.md
- Product: aspnet-core
- GitHub Login: @Rick-Anderson
- Microsoft Alias: riande
This was resolved by following the instructions in #7521.