Hard Links between UNIX Utility Programs

Willy Konijnenberg willy at philapd.UUCP
Sun Aug 7 06:59:37 AEST 1988


In article <153 at ispi.UUCP> jbayer at ispi.UUCP (id for use with uunet/usenet) writes:
>
>Another workable solution is to do the following steps:
>	4.	Make the owner of the shell script the super user
>	5.	Set the user bit for the shell script (chmod u+s name)

This works only if you have a shell that acknowledges the suid bit!
The Korn shell does that ONLY IF explicitly installed to do so,
the standard SV Bourne shell does NOT.
I don't know about the C-shell or any other shells.

If your shell does not handle the suid bit, you will have to write
a small front end in C to call the shell script.
This front end merely does an execvp of the shell script with it's argv.

BTW, You could have the shell script check it's arg0 to determine the
action to be taken, and use links to make all "sensitive" commands end
up in this single shell script.  (Weren't links the original problem? :-)
-- 
Willy Konijnenberg			<willy at idca.tds.philips.nl>
Philips Telecommunication & Data Systems, Department SSP/V2.
Apeldoorn, The Netherlands.



More information about the Comp.bugs.4bsd.ucb-fixes mailing list