Comment 15 for bug 328575

Revision history for this message
In , Hp-pobox (hp-pobox) wrote :

One question to ask; DBUS_SESSION_BUS_ADDRESS is modeled on DISPLAY and our answer to "how should it work?" has always been "just like DISPLAY"; so, how do the X server and DISPLAY work in your setup? The Correct Fix is probably for dbus to work in exactly the same way.

This is also the answer for ssh forwarding, etc.

I'm not sure I get how this is a bug; if you have DBUS_SESSION_BUS_ADDRESS set to the wrong value, that is just like setting a DISPLAY that you can't connect to. Don't do that then. I can't quite tell from the comments, but I think using "su -" would fix the problem, wouldn't it? That's what should be done if switching to a random user.

I mean, either you want a new login session with its own dbus, i.e. don't want DBUS_SESSION_BUS_ADDRESS; or you want to share the old login session so want to forward DISPLAY and DBUS_SESSION_BUS_ADDRESS, *and* you want to ensure the new session has the right cookies to authorize to the old display and dbus-daemon.

But I don't see how it's possibly correct to create a situation where DBUS_SESSION_BUS_ADDRESS are forwarded to the new session, *and* no cookies and auth are set up, so they don't work. Either forward the env variables and make them work, or don't forward them. Right? What am I missing?