|
|
|
@ -9,13 +9,17 @@ namespace Volo.Abp.Identity.AspNetCore
|
|
|
|
|
)]
|
|
|
|
|
public class AbpIdentityAspNetCoreModule : AbpModule
|
|
|
|
|
{
|
|
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context)
|
|
|
|
|
public override void PreConfigureServices(ServiceConfigurationContext context)
|
|
|
|
|
{
|
|
|
|
|
context.Services
|
|
|
|
|
.GetObject<IdentityBuilder>()
|
|
|
|
|
.AddDefaultTokenProviders()
|
|
|
|
|
.AddSignInManager();
|
|
|
|
|
PreConfigure<IdentityBuilder>(builder =>
|
|
|
|
|
{
|
|
|
|
|
builder.AddDefaultTokenProviders();
|
|
|
|
|
builder.AddSignInManager();
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void ConfigureServices(ServiceConfigurationContext context)
|
|
|
|
|
{
|
|
|
|
|
//(TODO: Extract an extension method like IdentityBuilder.AddAbpSecurityStampValidator())
|
|
|
|
|
context.Services.AddScoped<AbpSecurityStampValidator>();
|
|
|
|
|
context.Services.AddScoped(typeof(SecurityStampValidator<IdentityUser>), provider => provider.GetService(typeof(AbpSecurityStampValidator)));
|
|
|
|
|