Seeing the session bus as another user

Thiago Macieira thiago at kde.org
Wed Mar 7 09:57:31 PST 2007


David Zeuthen wrote:
>This kinda sounds like a hack to me. How is that going to work for
>multiple sessions? Think fast-user-switching, multi-seat, hot desking /
>terminal services...

That's exactly why the system bus is recommended: there's only one of it, 
whereas there are multiple session buses if you have multiple sessions.

If you need to emit a signal from one user to another via D-Bus, your 
options are:

1) setuid() and connect to that user's session bus (whose address you must 
obtain through external means)

2) connect to a private connection (whose address you must obtain through 
external means)

3) send the signal over the system bus (whose address is well known)

-- 
  Thiago Macieira  -  thiago (AT) macieira.info - thiago (AT) kde.org
    PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/dbus/attachments/20070307/852a030a/attachment.pgp


More information about the dbus mailing list