[systemd-devel] Shutdown notify
gmane at colin.guthr.ie
Wed Aug 20 08:13:59 PDT 2014
Lennart Poettering wrote on 20/08/14 14:58:
> On Wed, 20.08.14 15:50, Michal Witanowski (m.witanowski at samsung.com) wrote:
>> The inhibit locks mechanism seems to be the solution, but another problem
>> appeared. I am unable to call Inhibit() method as non-root user. In the
>> documentation I read "Taking inhibitor locks is a privileged operation.
>> Depending on the action...". But how can I add a user to privileged users
>> group? Note that I do NOT have PolicyKit in the system...
> Well, PK is how we open up those calls for unpriviliged clients...
> If you don't have PK then this functionality will not be available...
I suppose in an embedded env then creating a totally trivial setuid
wrapper and shelling out to /usr/bin/systemd-inhibit would be a suitable
alternative to PK.
Not nice and obviously you have to be careful not to write an
exploitable setuid wrapper, but might be what you need in this case?
Tribalogic Limited http://www.tribalogic.net/
Mageia Contributor http://www.mageia.org/
PulseAudio Hacker http://www.pulseaudio.org/
Trac Hacker http://trac.edgewall.org/
More information about the systemd-devel