Best way to gain root privileges

GSO gsowww at
Thu Feb 17 01:00:16 CET 2011

OK, thanks for the tips.

gksu* does not seem to be included with RHEL6 Desktop (though there is
a package called beesu), and besides which it appears gksu is
deprecated[1].  Either way c wrapper or sudo approach it is a tactical
decision, and the former is probably a better option with the problem
I have (though I will at the end of the day probably use both).  I
googled c wrapper and there are a ton of issues, type of c system call
to use, closing/reopening file handles, etc.  Whole books have been
written on the subject.  The philosophy at the end of the day I think
is do your own thing so a hacker cannot download the code you used.

Having said that I'm possibly arriving at the conclusion that a quick
perl script might be the simplest/easiest and most secure option - I
read perl includes code to safely run suid perl scripts - will dig out
my perl tomes.


On 16 February 2011 22:45, Emile van Sebille <emile at> wrote:
> On 2/16/2011 1:26 PM GSO said...
>> I'm sure this question is as old as time, but what is the best way to
>> gain root privileges?  (Am using Python 2.6.5, pygtk2 v2.16, Gtk
>> v2.18.9, on RHEL6.)
> have root's password?
> Emile
> --

More information about the Python-list mailing list