On Tue, Jun 10, 2003 at 18:25:11 +0200, Vincent Lefevre wrote: > I have written a setuid/setgid-root Perl script that does the > following: > > #!/usr/bin/suidperl -T > > use strict; > use warnings; > > $ENV{'PATH'} = '/usr/sbin:/usr/bin:/sbin:/bin'; > > @ARGV == 1 and my ($isp) = $ARGV[0] =~ /^([-0-9A-Za-z_]+)$/ > or die "Usage: ppp-on <ISP>\n"; > > $< = $>; # set real to effective uid [...]
FYI, the problem was solved by setting the gid too: $( = $); (thanks to Thomas Hood for the suggestion). -- Vincent Lefèvre <[EMAIL PROTECTED]> - Web: <http://www.vinc17.org/> - 100% validated (X)HTML - Acorn Risc PC, Yellow Pig 17, Championnat International des Jeux Mathématiques et Logiques, TETRHEX, etc. Work: CR INRIA - computer arithmetic / SPACES project at LORIA -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]