I'm new with dbus(Using Ubuntu 14.04, Unity). So I'm logged with user A, create process as user B and that process creates session for user B, now I want to use dbus messages to shut down session from that process for user B. I want my process to work on every desktop env. So I have download tool called d-feet, and started to play with it, I've noticed that everytime session is created in system /org/freedesktop/User/1002 is added(1002 is UID for user B) in org.freedesktop.login1.
So I tried to launch:
sudo dbus-send --type=method_call --print-reply --system --dest=org.freedesktop.login1 /org/freedesktop/login1/user/1000 org.freedesktop.login1.User.Terminate
But it gives me error saying Error org.freedesktop.DBus.Error.UnknownObject: Unknown user, I used ctr+alt+f1 login in as user B, launched startx and from user A-s desktop I used same command, it gives error saying 'GDBus.Error:org.freedesktop.DBus.Error.UnknownObject: Permission Denied' But this time it works(shuts downs session). I'm little lost. Hope you can help. Thanks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.