/// <summary>
 /// Configure User Identity - ASP.NET Identity
 /// </summary>
 /// <typeparam name="THttpUser">Implementation of ISystemUser</typeparam>
 /// <returns></returns>
 public static ISsoConfigurationBuilder ConfigureUserIdentity <THttpUser>(this IServiceCollection builder)
     where THttpUser : class, ISystemUser
 {
     builder
     .BaseSsoConfiguration <THttpUser>()
     .AddIdentity <UserIdentity, IdentityRole>(AccountOptions.NistAccountOptions())
     .AddEntityFrameworkStores <ApplicationSsoContext>()
     .AddDefaultTokenProviders();
     return(new SsoBuilder(builder));
 }
        // This method gets called by the runtime. Use this method to add services to the container.
        public void ConfigureServices(IServiceCollection services)
        {
            services.AddDbContext <ApplicationDbContext>(options =>
                                                         options.UseSqlServer(
                                                             Configuration.GetConnectionString("DefaultConnection")));

            services.AddDefaultIdentity <IdentityUser>(AccountOptions.NistAccountOptions())
            .AddEntityFrameworkStores <ApplicationDbContext>()
            .AddDefaultTokenProviders();
            services.UpgradePasswordSecurity().UseArgon2 <IdentityUser>();

            services.AddControllersWithViews();
            services.AddRazorPages();
        }