This is the mail archive of the
mailing list for the Cygwin project.
Re: About the 'su' command
- From: Brian dot Kelly at empireblue dot com
- To: cygwin at cygwin dot com
- Date: Mon, 30 Jun 2003 09:57:04 -0400
- Subject: Re: About the 'su' command
| O O |
| ^ |
\ \____/ /
"Igor Pechtchanski" <firstname.lastname@example.org> on 06/30/2003 08:45:48 AM
Please respond to email@example.com
Subject: Re: About the 'su' command
That's the reason behind the cygdaemon effort. So "somebody" is doing
On Mon, 30 Jun 2003 Brian.Kelly@empireblue.com wrote:
> >> Why rewrite 'su' to do those types of tricks, when 'ssh' already
> Uhhh - how about "script portability??"
> (Which is why I predict su will "someday" be made to do this. When??
> When somebody does it .... ) [ I ain't demand'in nothin from nobody ]
> Brian Kelly
> "Karsten M. Self" <firstname.lastname@example.org>@cygwin.com on 06/29/2003
> Sent by: email@example.com
> To: firstname.lastname@example.org
> cc: (bcc: Brian Kelly/WTC1/Empire)
> Subject: Re: About the 'su' command
> Is this, or could this be made, part of the standard Cygwin docs and/or
> Very nice explanation, Bill.
> on Wed, Jun 18, 2003 at 08:51:24AM -0400, Bill C. Riemers
> (email@example.com) wrote:
> > > The second says the command wont work unless I have appropriate
> > > privileges.
> > > Do you know "someone" on an XP station that has more powers than the
> > > Administrator or an Administrators member ?
> > On most Unix systems, if you create a user with UID 65535 you will find
> > user is unable to run 'suid' commands including 'su'. This is result
> > 65535 mapping to -1 as a short, and -1 having special meaning. For
> > there was a trend to make the "nobody" user 65535. But then with the
> > of the web, programmers started wanting to make SUID cgi-bin scripts,
> > still using "nobody" as the default user for web connections. As such,
> > practice using 65535 for "nobody" has for the most part been abandoned
> > the Unix world.
> > However, someone at Microsoft must have thought this was an extremely
> > idea. And why just have one account which is not allowed to SUID? So
> > instead, Microsoft wrote XP so any account != UID 18 is prohibited from
> > SUID. (OK. I over simplified, you can actually grant other accounts
> > privilege to SUID on XP professional...)
> > At first thought, the idea of restricting SUID to SYSTEM seems to give
> > much stronger security than most unix systems. Until, you stop and
> > consider, if only SYSTEM can SUID, and I can't login as SYSTEM, how
> > anything ever get installed to run under SYSTEM? It turns out SYSTEM
> > account used for running services. Anyone with Administrators
> > add a new service. Consequently, all Administrators can run any
> > they like as SYSTEM, including of course 'su'.
> > So, you ask, if it is so easy for Administrator to run a process as
> > why doesn't 'su' use this trick? Quite simple. You can not change an
> > existing process to SYSTEM privileges, nor can you do a direct exec()
> > can pass your open file descriptors and environment to the new process.
> > Consequently, you would find that if su used this "trick" your process
> > be running under a new TTY without access to existing file descriptors.
> > a command like, 'su root -c "bar.sh" < /tmp/foo' would not work as
> > Now you ask, "Well then, why can ssh do pipes." Very simple, 'ssh'
> > around after starting the child process starts passing data from open
> > descriptors though sockets.
> > Finally you ask, "If ssh can do that, why doesn't su?" Simple. Why
> > 'su' to do those types of tricks, when 'ssh' already exists?
> > Bill
|\ _,,,---,,_ firstname.lastname@example.org
ZZZzz /,`.-'`' -. ;-;;,_ email@example.com
|,4- ) )-,_. ,\ ( `'-' Igor Pechtchanski, Ph.D.
'---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow!
"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster." -- Patrick Naughton
"WellChoice, Inc." made the following
annotations on 06/30/2003 09:58:54 AM
Attention! This electronic message contains information that may be legally
confidential and/or privileged. The information is intended solely for the
individual or entity named above and access by anyone else is unauthorized.
If you are not the intended recipient, any disclosure, copying, distribution,
or use of the contents of this information is prohibited and may be unlawful.
If you have received this electronic transmission in error, please reply
immediately to the sender that you have received the message in error, and
delete it. Release/Disclosure Statement
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html