Please comment on my session timeout solution
Hi All
Please comment on my solution that is a spin off of what I've read at
http://osticket.com/forums/project.php?issueid=174#note807(http://osticket.com/forums/project.php?issueid=174#note807).
Here is the .htaccess file in my installation looks like in the root of my osticket installation.
php_flag short_open_tag on
php_value session.gc_maxlifetime "10800"
php_value session.save_path "/var/www/osticket_session"
I set the session.gc_maxlifetime to 3 hours and change the save path to
php_value session.save_path "/var/www/osticket_session"
I created the directory /var/www/osticket_session
To make this safer
chmod 733 /var/www/osticket_session
chmod +t /var/www/osticket_session
So you end up with
drwx-wx-wt osticket_session
Maybe I should move this folder outside /var/www/??
What do you think?? It appears to be secure to me.
I don't have any websites that run straight from the www folder they are all in other folders.
I started investigating this after seeing how php protects it's default session folder. /var/lib/php5
I read about chmod +t at http://www.comptechdoc.org/os/linux/usersguide/linux_ugfilesp.html(http://www.comptechdoc.org/os/linux/usersguide/linux_ugfilesp.html)
Here's what I read, the author had just created a folder and chmod 777 on it:
Everyone can read, write, and access the directory. The "t'' indicates that only the user(and root, of course) that created a file in this directory can delete that file.
To set the sticky bit in a directory, do the following:
chmod +t data