Beispiel #1
0
        public static UserManager Create(IdentityFactoryOptions <UserManager> options,
                                         IOwinContext context)
        {
            SoccerIdDbContext db      = context.Get <SoccerIdDbContext>();
            UserManager       manager = new UserManager(new AppUserStore(context.Get <SoccerIdDbContext>()));

            manager.UserValidator = new UserValidator <User, int>(manager)
            {
                AllowOnlyAlphanumericUserNames = false,
                RequireUniqueEmail             = true
            };
            manager.PasswordValidator = new PasswordValidator
            {
                RequiredLength          = 6,
                RequireNonLetterOrDigit = true,
                RequireDigit            = true,
                RequireLowercase        = true,
                RequireUppercase        = true,
            };
            return(manager);
        }
Beispiel #2
0
 public AppUserStore(SoccerIdDbContext context)
     : base(context)
 {
 }