Re: KSH setuid script doesn't work?
Posted in 1996
Topics: General Discussion
> In article <4dei14$i2b@ns.oar.net>, > William Harris <william@carsinfo.com> wrote: > > > >I may be describing it in reverse of what actually happens, but the > result is > >that setting the suid bit on a script or program is not sufficient > to get a > >script to run as that user. Do you have a #!/bin/ksh (or whatever your favorite shell is) as the first line? If you do then that will cause the shell to spawn another shell to actually run the shell script. To prevent this from happening you can take out the #!/bin/ksh, if your shell is the same shell that you created the shell script for. Otherwise you need to create an executable that has the setuid bit set and have that call the shell script. =========================================================================== David Sandmann ########### ########## ConferTech International, Inc. ## ##### 12110 N. Pecos #### ##### Westminister, CO 80234 ###### ##### Email: sandman@ziggy.cfer.com ###### ##### Phone: 303-633-3094 ################## ##### Fax: 303-633-3001 ################ ### ############## # ===========================================================================