To invalidate a session means to remove the HttpSession object and its
values from the system. IMHO Tomcat should be returning null if you
immediately call getSession(false) after an invalidate(), unless in it's
(mis)implementation it is automatically reallocating another HttpSession. I
remember there was also a bug concerning invalidate in 3.2 beta6:

http://w6.metronet.com/~wjm/tomcat/2000/Nov/msg00192.html

Otherwise are you sure there's not a call to getSession(true) in your code
between the two calls anywhere ?

HTH
Regards,
John Gunning

-----Original Message-----
From: A mailing list for discussion about Sun Microsystem's Java Servlet
API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of
Bartsch Axel
Sent: Monday, 12 March 2001 9:16 PM
To: [EMAIL PROTECTED]
Subject: TOMCAT 3.2: session invalidate does not work


Hi,

I use TOMCAT 3.2
I tried to invalidate a session by calling HttpSession session.invalidate()

The session is not really invalidated. If the user clicks he does not get
the same sessionId (with request.getSession(false)) as before the
invalidate() call:
but he gets a session with another sessionId: somehow the invalidate()
routine creates a new cookie with another sessionId. Strange is that I never
created this sessionId before.

Does anybody know about this?


Axel    Lannion/France

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".

Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to