Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!burl!ulysses!mhuxl!eagle!harpo!seismo!hao!hplabs!sri-unix!edhall@rand-unix From: edhall%rand-unix@sri-unix.UUCP Newsgroups: net.unix Subject: Re: perror(3) considered harmful Message-ID: <17334@sri-arpa.UUCP> Date: Thu, 8-Mar-84 17:33:00 EST Article-I.D.: sri-arpa.17334 Posted: Thu Mar 8 17:33:00 1984 Date-Received: Sun, 11-Mar-84 00:36:52 EST Lines: 23 From: Ed_Hall> ...The fact that > the kernel handles "#!" in a shell script is a major blunder. The kernel > has no business opening shell scripts and poking around in them... > ...Why should the kernel know > ANYthing about the semantics of command files? Leave it to a program (say, > csh or sh, radical suggestion!) to parse command files. I suspect that you've never made a SUID shell script. It is impossible without putting #! implementation in the kernel (unless you want to eliminate system security). The few hundred bytes of code needed to implement #! in the kernel is code well spent, in my opinion. Incidently, let me remind anyone who wants to make a SUID shell script to *always* explicitly set the search path ($PATH or $path) at the beginning of the script, and to *never* include the current directory (or any relative pathname) in that path. To do otherwise is to leave a security hole a mile wide. -Ed Hall ARPA: edhall@rand-unix UUCP: decvax!randvax!edhall