/*--------------------------------------------------------------------------------------------*/ public void SetUserCookie(long?pUserId, bool pRememberMe) { Tuple <Cookie, TimeSpan> pair = AuthUtil.CreateUserIdCookie(pUserId, pRememberMe); Cookie c = pair.Item1; c.Expires = DateTime.UtcNow.Add(pair.Item2); Cookies.Add(c); }
/*--------------------------------------------------------------------------------------------*/ private IDictionary <string, string> BuildRequestAuthCookies(SetupUserId pUserId) { Cookie c = AuthUtil.CreateUserIdCookie((long)pUserId, false).Item1; var cookies = new Dictionary <string, string>(); cookies.Add(c.Name, c.Value); return(cookies); }