Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: suidperl

by Erik Hensema (Sexton)
on Dec 10, 2001 at 21:39 UTC ( #130715=note: print w/replies, xml ) Need Help??


in reply to suidperl

Your scripts should never start with

#!/usr/bin/suidperl -w

Allways just use /usr/bin/perl.

suidperl is needed to be able to run scripts setuid. Usually this is impossible, because scripts are handled by an interpreter which isn't installed setuid.

'Running setuid' means that a program is started as if it was started by it's owner. So, if a file is owned by root:root and is setuid, it would be running with root priveliges regardless of what user started it. On startup, suidperl will change it's effective user-id to the id of the script's owner.

Read man perlsec for more information.

A script however is started with the permissions of the interpreter. So, if you make a script setuid it wouldn't have any effect. This is where suidperl comes in: suidperl is usually installed setuid root:root and is automatically invoked by perl when perls sees the scripts it's about to start is setuid.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://130715]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2018-09-24 04:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Eventually, "covfefe" will come to mean:













    Results (191 votes). Check out past polls.

    Notices?
    • (Sep 10, 2018 at 22:53 UTC) Welcome new users!