Date: Fri, 4 Jan 2002 18:18:50 +0200 From: "Dave Raven" <dave@kill-9.za.net> To: <freebsd-questions@FreeBSD.org> Subject: More SUID questions. Message-ID: <001801c1953b$80e0a6a0$3800a8c0@DAVE>
next in thread | raw e-mail | index | archive | help
Hello all,
I'm trying to get my sh script (with a goal of doing with perl) to run
as root.
I am probably doing it ALL wrong, but any help would be much
appreciated.
This is what I have so far:
[root@order] ~ # uname -mrs
FreeBSD 4.4-STABLE i386
[root@order] ~ # cat test.sh
#!/bin/sh -p
whoami
echo "testtest" > /root/foo
[root@order] ~ # ls -l test.sh
-rwsr-xr-x 1 root wheel 49 Jan 4 18:18 test.sh
[root@order] ~ # su phoenix
su-2.05$ ./test.sh
phoenix
./test.sh: cannot create /root/foo: permission denied
What is it I'm doing wrong?
Thanks again;
Dave.
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?001801c1953b$80e0a6a0$3800a8c0>
