From owner-freebsd-questions Wed Sep 16 11:37:50 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA06736 for freebsd-questions-outgoing; Wed, 16 Sep 1998 11:37:50 -0700 (PDT) (envelope-from owner-freebsd-questions@FreeBSD.ORG) Received: from purplemedia.com (pc-37001.bc.rogers.wave.ca [24.113.37.39]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA06720 for ; Wed, 16 Sep 1998 11:37:41 -0700 (PDT) (envelope-from jkrushen@home.com) Received: from oblivion ([10.0.0.3]) by purplemedia.com with smtp (Exim 2.02 #1) id 0zJMWx-00022q-00 for freebsd-questions@freebsd.org; Wed, 16 Sep 1998 11:42:19 -0700 Message-ID: <000201bde1a0$82062660$0300000a@oblivion.purplemedia.com> Reply-To: "Jordan Krushen" From: "Jordan Krushen" To: Subject: Setuid shell script problem Date: Wed, 16 Sep 1998 01:36:09 -0700 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 4.72.3155.0 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3155.0 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I have a setuid shell script which doesn't seem to be running as the owner's uid.. I'm sure I'm missing something, and I'm not sure what. Could anyone help this new-to-suid-scripts user get this to work? I know this a script-specific thing.. if i copy /usr/bin/id to my home dir and make it run suid root, I get: uid=1000(wired) euid=0(root) gid=1000(wired) groups=1000(wired), 0(wheel), 7(bin), 1011(samba), 1024(admin) which is correct, but through the script I get the following: # ls -l test -rwsr-x--- 1 root bin 13 Sep 16 01:34 test # cat test #!/bin/sh - /usr/bin/id # ./test uid=1000(wired) gid=1000(wired) groups=1000(wired), 0(wheel), 7(bin), 1011(samba), 1024(admin) Any help would be much appreciated. J. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message