You are not logged in.

#1 2006-02-02 10:31:39

mdv
Member
From: Poland
Registered: 2005-04-09
Posts: 145

Disallow users to poweroff, allow to hibernate.

Hello,
I'd like to disallow users to poweroff system but to allow them to run hibernate script. How can I do this?
Regards,
mdv

Offline

#2 2006-02-02 11:00:08

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: Disallow users to poweroff, allow to hibernate.

With sudo - although they will always be able to just turn off the machine, won't they? smile

Offline

#3 2006-02-02 13:56:33

mdv
Member
From: Poland
Registered: 2005-04-09
Posts: 145

Re: Disallow users to poweroff, allow to hibernate.

That's why I don't want to use sudo.

Offline

#4 2006-02-02 16:09:48

elasticdog
Member
From: Washington, USA
Registered: 2005-05-02
Posts: 995
Website

Re: Disallow users to poweroff, allow to hibernate.

tomk wrote:

With sudo - although they will always be able to just turn off the machine, won't they? smile

What do you mean?  You don't have to give them permissions to use all commands...for instance, using <code>sudo</code>I allow anyone that's in a group called <code>shutdown</code> to power off my machine from Xfce without needing a password:

%shutdown ALL = (root) NOPASSWD: /opt/xfce4/libexec/xfsm-shutdown-helper

You could apply the same principal to the hybernation command...

--==EDIT==--
DOH!  I think I misunderstood you tomk...you're right, they could always just power off the machine physically if it is in front of them (not by using <code>sudo</code>).

Offline

#5 2006-02-02 17:12:51

tomk
Forum Fellow
From: Ireland
Registered: 2004-07-21
Posts: 9,839

Re: Disallow users to poweroff, allow to hibernate.

That was my point alright - that big old power switch will always be there...........

Offline

#6 2006-02-03 14:56:24

mdv
Member
From: Poland
Registered: 2005-04-09
Posts: 145

Re: Disallow users to poweroff, allow to hibernate.

You're right. Thank you.

Offline

Board footer

Powered by FluxBB