Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

setuid: Perl v C

by eyepopslikeamosquito (Archbishop)
on May 05, 2003 at 06:23 UTC ( [id://255570]=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    wr.c (C wrapper):
    
    ...
       sArgv[4] = 0;
       execv("/usr/bin/perl", sArgv);
    }
    
  2. or download this
    Example Perl script t1.pl:
    
    ...
    print "arg1='$arg1'\n";
    dump_user_details($<);
    dump_user_details($>) if $> != $<;
    
  3. or download this
    cc -o wr wr.c
    chown root wr t1.pl
    ...
    chmod 4710 wr
    ./wr test
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://255570]
Approved by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2024-04-26 08:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found