[Patch] Allow to disable root privileges with CYGWIN=noroot
Christian Franke
Christian.Franke@t-online.de
Sat Aug 29 14:05:00 GMT 2009
For members of administrator group, Cygwin runs with root access rights.
Cygwin enables the Windows backup and restore privileges which are not
enabled by default.
This is IMO not desirable under all circumstances.
This patch adds a new flag to the Cygwin environment variable.
If 'CYGWIN=noroot' is set, the extra privileges are removed after Cygwin
startup.
This allows to run a Cygwin shell with the same default access rights as
cmd or explorer.
Testcase:
$ cd /cygdrive/c
$ ls -l 'System Volume Information'
----rwx--- 1 root SYSTEM 0 Feb 22 2009 MountPointManagerRemoteDatabase
...
$ CYGWIN=noroot ls -l 'System Volume Information'
ls: cannot open directory System Volume Information: Permission denied
I'm sure there is something missing, so no changelog for now :-)
Christian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cygwin-1.7-env-noroot.patch
Type: text/x-patch
Size: 2753 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20090829/cc1e6fa3/attachment.bin>
More information about the Cygwin-patches
mailing list