in reply to Re: setuid: Perl v C
in thread setuid: Perl v C

In my little example, the C wrapper wr is setuid, not the interpreter (I am not attempting to use the suidperl binary). The example I posted seems to work fine on Linux. The C wrapper technique I am using is mentioned near the end of perlsec; if I am missing something here, please let me know, as I am no security guru.

The script is to run at many customer sites and it is unacceptable to ask them to install sudo. The people who run it may not have the root password yet root permissions are required to mess with installing/loading device drivers (which is what the script does).