Ok, I have seen the code to enable retry lockouts,
public async Task<ActionResult> Login(LoginViewModel model, string returnUrl) { ... SignInManager.UserManager.DefaultAccountLockoutTimeSpan = new TimeSpan(1, 0, 0); SignInManager.UserManager.MaxFailedAccessAttemptsBeforeLockout = 5; //5 was default var result = await SignInManager.PasswordSignInAsync(model.Email, model.Password, model.RememberMe, shouldLockout: true);
now I want to put a link on the user manager screen that
- only appears if a user is Retry Locked Out. (Somehow read the ASPNetUser from the ApplicationUser and check the lockout status)
- Executes the await UserManager.ResetAccessFailedCountAsync(userId); command when clicked.
the only problem I am having is that the framework has created so many levels of obfuscation that I cant see how to get the lockout status of an "ApplicationUser"