tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew E. Davidson" <a...@bonsaidevelopment.com>
Subject how to control lifetime of JSessionID cookie in Tomcat 5.5
Date Tue, 04 Apr 2006 00:14:31 GMT
Hi 

 

I am trying to figure out how to set up my application so that users are
only forced to log on every couple of day. Sort of like my.yahoo.com. If you
click "remember my id" you can close/restart you browser and not have to log
back in again.

 

Here is part of my web.xml file

 

<session-config>

 

      <!-- the session time out is set so that they can 

 

            be idle for about 1.5 days

 

      -->

 

      <session-timeout>2160</session-timeout>

 

</session-config>

 

I think the problem that that the jsessionid cookie is not being created
correctly. When I looked at the cookie in my browser, I noticed that Expires
was set to "at end of session". Any one know how I can configure this? 

 

I guess I could create a filter, to get the cookie and call setMaxAge(), how
ever its seems like I should not being writing this kind of code

 

Any help would be greatly appreciated

 

Andy

 

 


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message