Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site elsie.UUCP Path: utzoo!watmath!clyde!floyd!harpo!seismo!rlgvax!cvl!elsie!ado From: ado@elsie.UUCP Newsgroups: net.unix-wizards Subject: Re: kernel recognizing #! scripts Message-ID: <833@elsie.UUCP> Date: Fri, 9-Mar-84 15:52:52 EST Article-I.D.: elsie.833 Posted: Fri Mar 9 15:52:52 1984 Date-Received: Sat, 10-Mar-84 12:48:50 EST References: <117@ios.UUCP> Organization: NIH-LEC, Bethesda, MD Lines: 19 One advantage to having the kernel recognize #! scripts is that set-uid/gid mode works. Just as with a binary, the kernel recognizes this mode and starts the shell or whatever with appropriate effective uid/gid. On 4.1bsd, scripts without #! ignore set-uid mode. . . Rich Altmaier, Integrated Office Systems. decwrl!ios!richa Note, however, that in a binary program you can issue a system call to reset the user (or group) id to the "real" (as distinct from the effective) id. I've yet to learn of a way to do this in shell scripts. Maybe the unavailable korn shell supports it. -- The "unix" in "net.unix-wizards" is a down-cased variant of "UNIX" (please note: all UPPER CASE), which is a Bell Labs trademark. -- UUCP: decvax!harpo!seismo!rlgvax!cvl!elsie!ado DDD: (301) 496-5688