Roundcube Community Forum

 

Auto Log out timing and removing @ on login

Started by finch13, August 11, 2006, 11:45:23 AM

Previous topic - Next topic

finch13

Roundcube seems to auto log out after only a couple minutes. Is it possible to edit something to keep it logged in longer? Or even forever?

Also, I tried editing the main php file on this line: $rcmail_config['username_domain'] = '';

I changed it to 'domain.com' where domain is my website address.
 
That didn't seem to work.

What I need to do to login right now is type user+domain.com.  maybe the + in place of the @ is messing it up? Any ideas?

-Dan Finch

flash

in the config file

$rcmail_config['session_lifetime']

$rcmail_config['username_domain']

finch13

I think I can figure out the session_lifetime one.

Username_domain, however, doesn't seem to work.

i changed to to 'mydomain.com' (in my case finch13.com) and it didn't work. Could it have to do with the fact I need to login with user+finch13.com and not [email protected]?

flash

That I do not know. Hopefully someone esle will come along that does :(

jrmy

Just looked at the code and it looks like the @ had been hard coded into roundcube.

First set this to your domain name.
$rcmail_config['username_domain'] = '';


Then open up roundcubemail/program/include/main.inc

Find:
/* Modify username with domain if required
   Inspired by Marco <P0L0_notspam_binware.org>
 */
 // Check if we need to add domain
 if ($CONFIG['username_domain'] && !strstr($user, '@'))
  {
  if (is_array($CONFIG['username_domain']) && isset($CONFIG['username_domain'][$host]))
   $user .= '@'.$CONFIG['username_domain'][$host];
  else if (!empty($CONFIG['username_domain']))
   $user .= '@'.$CONFIG['username_domain'];  
  }

Replace with
/* Modify username with domain if required
   Inspired by Marco
 */
 // Check if we need to add domain
 if ($CONFIG['username_domain'] && !strstr($user, '@'))
  {
  if (is_array($CONFIG['username_domain']) && isset($CONFIG['username_domain'][$host]))
   $user .= '+'.$CONFIG['username_domain'][$host];
  else if (!empty($CONFIG['username_domain']))
   $user .= '+'.$CONFIG['username_domain'];  
  }


I have no way of checking to see if that works but it's work a shot. It should be noted that since this is hard coded in only the + will work from now on. But most webhosts allow the +...

This is something I think roundcube needs to fix as the + is common enough.

UPN1541

Quote from: finch13 Roundcube seems to auto log out after only a couple minutes. Is it possible to edit something to keep it logged in longer? Or even forever?

Okay... I'm getting the opposite! My two RoundCube beta 2 installs (same host server) won't auto log out... EVER.

I installed a 3rd beta 2 and it wont log out either, HOWEVER I was composing an email, it popped up as auto save to drafts, then when I hit send it said my session was invalid. I can't reproduce it. I cleared my browser cache, deleted cookies, tried three different browsers: Safari, Opera, Firefox.

I have main.inc.php configured:

// session lifetime in minutes
$rcmail_config['session_lifetime'] = 10;

Any ideas?

UPN1541

Any ideas as to why my installs of beta 2 wont auto log out or expire the session? Where as beta 1 would...

jrmy

I am not exactly sure but I am thinking the session time out does not apply to the auto logout. Since roundcube checks your mail every so often it would keep the session alive. I am thinking the auto logout is a seperate item roundcube may not have.