Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: builtin setuid and setgid commands
- X-seq: zsh-workers 22699
- From: Dave Yost <Dave@xxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Re: builtin setuid and setgid commands
- Date: Tue, 12 Sep 2006 13:57:39 -0700
- In-reply-to: <237967ef0609121251u4fa6cb4erd3061a267cf4a645@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <pdy98830624063bc12cb7255de8@xxxxxxxxxxx> <237967ef0609121251u4fa6cb4erd3061a267cf4a645@xxxxxxxxxxxxxx>
At 09:51 PM +0200 2006-09-12, Mikael Magnusson wrote:
>On 9/12/06, Dave Yost <Dave@xxxxxxxx> wrote:
>>Zshell should have builtins to call the setuid and setgid system calls.
>>
>>With this feature, one can write a shell script that is executed by
>>root but runs as another user.
>>
>>The usefulness of this feature came up in the context of the
>>mysql.server script, which starts/stops the server and is run by root
>>at boot time. It would be nice if the script itself could use a
>>setuid command to ensure that it is running as the mysql user.
>>
>>Thanks
>>
>>Dave
>
># whoami
>root
># UID=1003
># whoami
>mikaelh
># UID=0
># whoami
>mikaelh
>
>another session
># whoami
>root
># EUID=1003
># whoami
>mikaelh
># EUID=0
># whoami
>root
>
>
>--
>Mikael Magnusson
Thanks. Also note:
0 516 Z% grep setuid /tmp/zshall.1
1 517 Z%
:)
Dave
Messages sorted by:
Reverse Date,
Date,
Thread,
Author