reopen 608301 retitle 608301 no access to sleep/wake D-Bus interface if root session active severity 608301 normal thanks
On 30.12.2010 10:56, Martin Steigerwald wrote: > Am Thursday 30 December 2010 schrieb Martin Steigerwald: >> Am Wednesday 29 December 2010 schrieben Sie: >>> On 29.12.2010 20:15, Martin Steigerwald wrote: >>>> Package: network-manager >>>> Version: 0.8.2-3 >>>> Severity: important >>>> >>>> shambhala:~> dbus-send --print-reply --system >>>> \ >>>> >>>> --dest=org.freedesktop.NetworkManager \ >>>> /org/freedesktop/NetworkManager \ >>>> org.freedesktop.NetworkManager.wake >>>> >>>> Error org.freedesktop.DBus.Error.AccessDenied: Rejected send >>>> message, 9 matched rules; type="method_call", sender=":1.369" >>>> (uid=0 pid=1467 comm="dbus-send) >>>> interface="org.freedesktop.NetworkManager" member="wake" error >>>> name="(unset)" requested_reply=0 >>>> destination="org.freedesktop.NetworkManager" (uid=0 pid=1360 >>>> comm="/usr/sbin/NetworkManager)) > [...] >>> This seems to be intentional: >>> http://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?h=N >>> M_ 0_8&id=878f6c4074acfdee42c320680f5529e01b909ba2 >>> >>> running as root works fine here. >>> >>> If you want to change this configuration, see >>> >>> /etc/dbus-1/system.d/NetworkManager.conf. >> >> But I am running as root! > > Its not even working from a tty1 where I directly logged in as root. Well, that is actually the problem. You are running the script as root with a full (ConsoleKit) session. I bet, in your other test, you had a ConsoleKit session for root registered, i.e. you had a file /var/run/console/root and ck-list-sessions showed a session for root. A CK session for root is registered, if you run su or if you login on the console. If you run sudo (which I did) no CK session is registered or if you trigger pm-suspend via D-Bus, the script runs with root privileges but no CK session. The issue now is, that as soon as you have CK session for root, no longer the <policy user="root"> ... </policy> section applies, but <policy at_console="true"> ... </policy>, which denies access to sleep/wake. Downgrading to normal, as pm-utils (and the NM sleep hook) is usually not triggered manually from within a complete root session. Dan, any suggestion how to address this issue? 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

