Possible Duplicate:
Difference between menu shutdown and 'shutdown -h now'
Why can ubuntu perform a shutdown from the GUI even though it is prive on the command line? By what mechanism does it do so?
Possible Duplicate:
Difference between menu shutdown and 'shutdown -h now'
Why can ubuntu perform a shutdown from the GUI even though it is prive on the command line? By what mechanism does it do so?
The mechanism seems to be a DBus message, sent to a process with root privileges. Taken from How can I make shutdown not require admin password?: