Cookies and multiple sessions



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

.



Relevant Pages

  • Re: Do IIS applications "go to sleep"?
    ... client side. ... This type of cookie is not disabled when one disables client ... using these session items. ... need your timer when you extend a session timeout to five days. ...
    (microsoft.public.dotnet.framework.aspnet)
  • RE: Wont save session object
    ... client machine's cookie setting. ... the ASP.NET's session is by default associated with all the client ... something incorrect with the client's cookie setting. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Hiding variables passed via URL
    ... unique session ID. ... That has to be carried by a cookie or by a URL. ... session ID as a URL than as a cookie. ... on a file on the server the client is communicating with. ...
    (comp.lang.php)
  • Re: WebService session sessionstate SOAP
    ... InfoPath as a client doesn't respect the session cookie. ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: WebService session sessionstate SOAP
    ... InfoPath as a client doesn't respect the session cookie. ...
    (microsoft.public.dotnet.framework.webservices)