Cookies and multiple sessions
- From: krishnamoorthy_ramesh@xxxxxxxxxxx
- Date: 16 Jan 2007 01:59:21 -0800
I have a unique situation (may be not so unique).
I have two applications that need to talk to a server through http
sessions.
One is a web application that I would launch in IE. Before launching
this application in IE, I do a background login using
CHttpFile.SendRequest, get a cookie and save it in the local cookie
store. This way, when the application launches in IE, it is already
logged in.
The other is a client running locally that should establish a session
with the server(using CInternetSession), send some requests, receive
responses and logout. (the client talks to a servlet)
Ok, now the issue is, when I launch the second client application,
since there is an already establised cookie, that cookie gets picked up
and recognized by the server and a new session is never created. So,
when the client logs out in the last step, the session becomes invalid.
At this point, if I try to do anything in the web application that is
open in IE, I am taken to the login page.
The question is, how can I force the client to establish a new session?
In other words, how can I force the client not to pick up the cookie
established by the background login process for the web application?
Is there a better way of what I am trying to do? (hosting the servlet
that the client talks to in a different path is not an option)
Thanks
.
- Follow-Ups:
- Re: Cookies and multiple sessions
- From: Igor Tandetnik
- Re: Cookies and multiple sessions
- Prev by Date: All about GIF file
- Next by Date: Re: inheriting the VC++ template classes into C#.net
- Previous by thread: All about GIF file
- Next by thread: Re: Cookies and multiple sessions
- Index(es):
Relevant Pages
|