session timeout suggestions wanted
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.php archive

session timeout suggestions wanted

From: Craig Storey <cstorey@canada.com>
Date: Thu Sep 22 2005 - 22:14:15 CEST

I have a form where users logged in using sessions can edit articles in
a WYSIWYG editor. Some of them take their time and don't like to save
their work very often and occassionally the sessions expire and their
work goes poof. (I've suggested editing off-line and simply copy+paste
  but they prefer the editor.)

After a lot of searching I've found the main culprit is
session.gc_maxlifetime and I can set it longet like...

ini_set('session.gc_maxlifetime', 7200); // 2 hour inactive session
timeout

Are there other timeouts I should worry about with Apache/Linux?
(Caches, etc..?) My other php.ini settings are...

session.cache_expire 180 -> 3 hours shouldn't be a problem
session.cookie_lifetime 0 -> this is don't expire while browser open
right?

Now a few of my Google searches came up with a scenario for timeouts
where the timezone of server and client have to be considered. i.e. If
server is ahead of client by 1 hour, is the session timeout reduced by 1
hour for that client. Can this be true??

Also are there any other problems with a php session lasting 2 hours?
Small site, not a lot of users with these priviledges or accessing the
editor.

Thanks for any advice.
Craig
Received on Tue Oct 18 02:26:54 2005