问题 I am authenticating a user: [Route("Login"), HttpPost, AllowAnonymous] public LoginViewModelResponse Login(LoginViewModelRequest data) { if(!Membership.ValidateUser(data.Username, data.Password)) { return new LoginViewModelResponse { DisplayMessage = "Invalid Username/Password!", IsSuccess = false, RedirectUrl = "/Home/" }; } FormsAuthentication.SetAuthCookie(data.Username, false); ClaimsIdentity identity = new GenericIdentity(data.Username); var roles = "Administrator,User".Split(','); //