Skip to content

const COOKIE_RC_SESSID #50

Description

@qraten

Hi! I noticed that in AuthRoundCube.php the code uses:

const COOKIE_RC_SESSID = 'roundcube_sessid';

But Roundcube uses
rcsessid

as the real cookie name (based on defaults.inc.php and the HTTP response headers).

After changing it to:
const COOKIE_RC_SESSID = 'rcsessid';

the Nextcloud integration started working better and I was able to reach the login screen — but auto-login still didn’t happen.
Could you explain why the plugin expects roundcube_sessid instead of rcsessid? Is this intentional or maybe based on an older Roundcube version?

Additionally, before changing the constant, I was getting this error:
"Could not get login redirect header and no sessauth cookie"
After changing it to rcsessid, the login page loads correctly but auto-login still fails. Any advice on how to debug this further?

Maybe it would be helpful to detect both variants (roundcube_sessid and rcsessid) depending on the Roundcube version?

config.inc.php
// CRUCIAL FOR RUNNING IN SUBFOLDER (like /roundcube/)
$config['log_driver'] = 'file';
$config['log_logins'] = true;
$config['debug_level'] = 8;
$config['session_path'] = '/roundcube/';
$config['force_https'] = true;
$config['use_https'] = true;
$config['session_same_site'] = 'Lax';
$config['session_domain'] = 'xxx.yyy.eu'; // required with subfolder!
$config['request_path'] = '';
$config['session_name'] = 'rcsessid';
$config['login_autocomplete'] = 2; // better form handling in iframe
$config['check_referer'] = false;
$config['ip_check'] = false;

My version Roundcube Webmail 1.6.11
My AuthRoundCube.php attached

AuthRoundCube.php

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions