[imp] session timing out way too soon

Roger Thomas sniper at home.net.my
Wed Dec 7 05:33:17 PST 2005


Quoting Jan Schneider <jan at horde.org>:

> Zitat von Roger Thomas <sniper at home.net.my>:
> 
> > I have been running Horde and IMP for the past two years or so.   
> > About a month ago my users (and me) have been experiencing session 
>  
> > timing out way-way too soon. Sometimes less than 5 minutes. It was 
>  
> > PERFECTLY okay before.
> 
> And what did you change back then?
> 
> Jan.
> 
> -- 
> Do you need professional PHP or Horde consulting?
> http://horde.org/consulting/
> -- 
> IMP mailing list - Join the hunt: http://horde.org/bounties/#imp
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: imp-unsubscribe at lists.horde.org
> 

Changes to IMP were last done too long ago for me to remember. At  least nothing were changed in the past 12 months. BTW, I am using mysql to store sessions.

A month ago, a fellow developer coded some kind of photo manipulation script. It resides on a different server altogether. But he wanted to have a single signon mechanism. Only those that have logged in to IMP can create their photo album.

- Just now I digged inside some of the photo album code and found a session variable by the name upload_path.
- then I dumped the content of Horde's session table and very surprised that upload_path is in there. Isn't Horde's session table only meant for Horde suite of application's usage only?
--- start of excerpt ---
logintasks|a:1:{i:0;a:2:{s:4:\"type\";i:0;s:7:\"message\";s:43:\"Last login: Wed 07 Dec 2005 03:58:20 PM \";}}upload_path|s:44:\"../photoDir/v/vietdelesm/family/\";');
--- end of excerpt ---

How did upload_path manage to find its way into Horde's session table?


- snipper of the photo upload script
<?
session_start();
$url_array = explode("/",$_SERVER['REQUEST_URI']);
$pos = count($url_array);
$id  = $url_array[$pos-1];

#URL validator
if(isset($id) && !is_numeric($id)) {
header("location:".GALL_URL.GALL_LINK_PATH.'photo_album/0');
exit;
}


$parent_id = $id;
$qstr = getPath();
$path ='';
        if(count($qstr)>3){
                for($i=3;$i<count($qstr)-1;$i++){
                if(!empty($qstr[$i])){
                        $path .= '/'.strtolower($qstr[$i]);
                       }
                }
        }

$url_path = $path;
$_SESSION['upload_path'] = GALL_USERID_PATH.$path."/";


Any clue ?

--
roger


---------------------------------------------------
Sign Up for free Email at http://ureg.home.net.my/
---------------------------------------------------


More information about the imp mailing list