Re: Roles and Permissions Caching Issue
I suspect this is going to turn out as a mono bug as I have not seen this in my testing on Windows.
I will try and come up with a simple test case this weekend.
The logout code is like this
Response.Cookies["portalroles"].Value = null;
Response.Cookies["portalroles"].Expires = new System.DateTime(1999, 10, 12);
Response.Cookies["portalroles"].Path = "/";
FormsAuthentication.SignOut();
Response.Redirect(SiteUtils.GetSiteRoot(), false);
I can try some different things and see if there is a workaround. For example I will try setting the cookie to string.Empty instead of null and try DateTime.Now.AddYears(-1)
I can also try some alternate syntax to set the cookie like
HttpCookie roleCookie = new HttpCookie("portalroles", string.Empty);
roleCookie.Expires = DateTime.Now.AddYears(-1);
HttpContext.Current.Response.Cookies.Add(roleCookie);
and see if that helps
It does sound like its the roles cookie is where the problem is happening. Sounds like it is sticking around after logout.
There have been some bugs in the cookie implementation of mono before.
I'll post again after I get a chance to investigate it further.