Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[HOWTO] spegnere e riavviare anche da utente
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

Goto page Previous  1, 2, 3  
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) Risorse italiane (documentazione e tools)
View previous topic :: View next topic  
Author Message
=DvD=
Veteran
Veteran


Joined: 25 Mar 2004
Posts: 1353

PostPosted: Wed Jul 27, 2005 1:21 pm    Post subject: Reply with quote

Non ho seguito tutta la discussione, ma con acpid non è possibile spengere la macchina col pusante sul case? (come su windows, lo pigi e parte lo shutdown...)
Back to top
View user's profile Send private message
gaffiere
Guru
Guru


Joined: 13 Nov 2003
Posts: 406
Location: Provincia Milano

PostPosted: Wed Jul 27, 2005 3:00 pm    Post subject: Reply with quote

=DvD= wrote:
ma con acpid non è possibile spengere la macchina col pusante sul case? (come su windows, lo pigi e parte lo shutdown...)
certo che si puo' :)

see ya
_________________
Thomaz "Gaffiere"
Middle-Earth XP2200+, 1Gb Ram, 80Gb + 160Gb Hd, SbLive!, Nvidia 6800GT AGP8x
Gentoo Gnu/Linux 2.6.12-gentoo-r10
Back to top
View user's profile Send private message
fctk
Veteran
Veteran


Joined: 28 Jan 2004
Posts: 1424
Location: Milan, Italy, EU

PostPosted: Sun Aug 14, 2005 4:26 pm    Post subject: Reply with quote

dopo aver letto questo howto: http://www.gentoo.org/doc/en/sudo-guide.xml ho pensato di alleggerire un po' la procedura per spegnere/riavviare da utente... in pratica:
Code:
# emerge -av app-admin/sudo
# visudo

e aggiungiamo:
Code:
%users  ALL = NOPASSWD: /sbin/shutdown

a questo punto basta creare degli alias semplici semplici:
Code:
# nano -w ~/.bashrc
alias halt='shutdown -h now'
alias reboot='shutdown -r now'
$ nano -w ~/.bashrc:
alias halt='sudo shutdown -h now'
alias reboot='sudo shutdown -r now'


non l'ho testato molto, ma sembra funzionare...
che ve ne pare?
Back to top
View user's profile Send private message
unz
l33t
l33t


Joined: 28 Jul 2004
Posts: 819
Location: Roma, Italia

PostPosted: Sun Aug 14, 2005 5:51 pm    Post subject: Reply with quote

Ricordo a chi ha >=gnome-2.10 può farlo senza impicci vari.

Desktop->Preferenze->Sessioni->Selezionare "Confermare al termine della sessione"

Poi eseguite il logout come al solito
_________________
Ma che c'hai là? Sulla spalla!!!! http://lascimmia.it/
Back to top
View user's profile Send private message
fraido
Tux's lil' helper
Tux's lil' helper


Joined: 17 Mar 2005
Posts: 109

PostPosted: Sun Aug 14, 2005 10:29 pm    Post subject: Re: la mia solzione Reply with quote

fedeliallalinea wrote:
lan wrote:
e così anche da utente normale potrete spegnere e riavviare il pc
ATTENZIONE l'atribuzione dei permessi +u è molto pericolosa in fatto di sicurezza, usatela con prudenza

La soluzione sudo mi pare molto meglio e molto piu' sicura


Non capisco perchè sudo dovrebbe essere più sicuro di chmod +u....
Alla fine sudo può essere considerato più "flessibile" di chmod, questo è vero.

Ad esempio invece di quanto scritto nell'howto si può impostare in modo tale che richieda la password:

Code:
%shutdown ALL= /sbin/reboot.sh
....


Ma dal punto di vista della sicurezza è la stessa identica cosa...(per lo meno così com'è stato scritto nell'howto); ovvero da il permesso a tutti gli utenti di dare il comando halt/reboot esattamente come si fa facendo chmod +u e questo secondo sistema non impone di installarsi del software il quale a sua volta può avere dei bug e quindi potenziali buchi di sicurezza! :wink:
Infatti sudo è un tool sconsigliato, in quanto può creare buchi grandi come case.
Questo è quello che so io....per caso mi sbaglio?

fraido
_________________
essere fraido non e' uno stato mentale, bensì una situazione di fatto; ovvero fraido si nasce, non si diventa!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) Risorse italiane (documentazione e tools) All times are GMT
Goto page Previous  1, 2, 3
Page 3 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum