Tag: Form Authentication

Request.IsAuthenticated always returning false MVC

I created new project and I did setup routes and other necessary functions, now it was turn for form authentication. I follow up all necessary steps, required to validate the user like creating cookie etc like below: var userData = JsonConvert.SerializeObject(serializeModel); var expiryDate = model.RememberMe ? DateTime.Now.AddDays(14) : DateTime.Now.AddDays(1); var ticket = new FormsAuthenticationTicket(1, model.UserName, DateTime.Now, …