FormsAuthentication.Encrypt(ticket) returns null
Friday, December 5th, 2008I’ve done a sample today and I need to create FormsAuthenticationTicket manually in order to make it inexpiable. I create specifying null for user data in the constructor.
1: FormsAuthenticationTicket ticket = new FormsAuthenticationTicket(1, FormsAuthentication.FormsCookieName,
2: DateTime.Now, expiredTime, persist, null, FormsAuthentication.FormsCookiePath);
3:
[...]