in reply to Re: Running Perl Suid
in thread Running Perl Suid

Another way is to set $ENV{PATH} yourself to a known, fixed, secure value.

In my case, I had to clear $ENV{BASH_ENV} to make it work. Clearly, your milage may vary, depending on what shell your perl uses.

perl -Te 'delete $ENV{BASH_ENV}; $ENV{PATH} = "/bin:/usr/bin"; system( +"clear");'