Yves-Alexis Perez wrote: > On mer, 2009-04-29 at 08:14 +0200, Michael Biebl wrote: >>> I aggree. I mean, libpam-ck-connector should _only_ sets the variable if >>> it's indeed an XDG_SESSION. I mean, only if the user logged in through a >>> CK-enabled DM. (I didn't yet test with slim and libpam-ck-connector >>> activated but I guess it won't work either). Those are the problematic >>> ones. I don't know if libpam-ck-connector can detect that they already >>> have a CK session, but that would make a lot more sense. >> Sorry, I do not quite understand what you mean by that. Maybe you can >> elobarate. > > Ok, see below. >> First, let me try to explain a few things: >> >> 1.) libpam_ck_connector is setup in common-session with the nox11 >> option. That means, a login via a login manager (e.g. gdm) will not >> create a CK session. > > Ha, that's fine, so slim will work. > >> So basically, what libpam_ck_connector is good for, is for logins on the >> console. After a login on the console, XDG_SESSION_COOKIE will be set. > > I don't really know why?
> >> 3.) /etc/X11/Xsession.d/90consolekit creates a CK session, if >> XDG_SESSION_COOKIE is not yet set. The check is there, to avoid creating >> to CK session cookies: one by the (g|k)dm login manager, and the other >> one from 90consolekit (libpam_ck_connector is not involved in graphical >> login, unless you explictely change the pam configuration) >> >> This is for users of a login manager, that does not directly talk to CK, >> but uses the standard Xsession integration (I think slim would be such >> an example). >> >> If you are using plain startx from the console and XDG_SESSION_COOKIE is >> not yet set, it should work, too. > > The I just fail to see why libpam-ck-connector from oustide of X creates > the XDG_SESSION_COOKIE. What is it used for? Trying to answer both of your questions: It's indeed questionable, what a CK session on the console is good for. But keep in mind, that there are command line tools out there, that e.g. use HAL or NetworkManager (powersave or a ITPed cnetworkmanager). This is far less common though, as the need for a CK session in X. So a first step to "avoid" this kind of problem, is indeed, to make the libpam_ck_connector Recommends a Suggests. It's obviously not a real fix. The only other reason I can think of, why libpam_ck_connector might be useful, is if you setup a custom pam configuration without nox11 for a login manager that does neither support Xsession.d nor talk to CK directly. >> 2.) login on the console (covered by libpam_ck_connector) > > Yes (but afaict we don't need XDG_SESSION_COOKIE) See below > Basically, I think I'd be fine with libpam-ck-connector not using > XDG_SESSION_COOKIE when it's in console mode (nox11) because it doesn't > really make sense. I think we can't get rid of the XDG_SESSION_COOKIE variable, as this is necessary to correctly track/assign a session to a user. (I'll verify that though) That's why I proposed the idea of an additional/separate env var, that will only be set for console logins, so we can easily differentiate X11 from console logins in Xsession.d/90consolekit. Cheers, Michael -- Why is it that all of the instruments seeking intelligent life in the universe are pointed away from Earth?
signature.asc
Description: OpenPGP digital signature

