I am encountering problems reading cookies in Classic ASP pages after logging out of the portal. Once logged out you have to delete the Cookie before accessing them through Classic ASP. I have traced the code and narrowed the root cause down to a method in UserDesktop.cs.

 

Code trace:

Logoff.asp->PortalSecurity.SignOut()->Rainbow.BLL.UserConfig.UserDesktop.ResetDesktop(uid)-> UserDesktop.FindUserWindows(uid)->

 

1     private static Rainbow.BLL.User.UserWindowMgmt  FindUserWindows(int uid)

2           {

3    

4                 HttpContext ctx =  HttpContext.Current;               // get user id

5                 string userid = uid.ToString();

6                      

7                 // if there is no user (anonymous)

8                 if ( uid != 0 )

9                 {

10                      // need data bag for the session

11                      BLL.Utils.IWebBagHolder bag = BLL.Utils.BagFactory.instance.create(BLL.Utils.BagFactory.BagFactoryType.CookieType);

12                      // set the user id information

13                      userid = (string) bag[Rainbow.Configuration.GlobalInternalStrings.UserWinMgmtIndex];//Comment out this line and the problem goes away.

14                }

15                // get the user's window information

16                return new UserWindowMgmt(userid);

17               

18          } // end of FindUserWindows

 

The comment on line 7 does not make sense to me. It appears it the code does the opposite of the comment. Can someone help me evaluate if this is working as intended or is there a possible bug here.

 

 

 

Thanks

 

 

John Achbach

MCSD,MCP+SB,MCT

Senior Software Engineer

Meyer Distributing

 

MSN Messenger:john_achbach@yahoo.com

johna@meyerdistributing.com