delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/11/23/07:17:21

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Fri, 23 Nov 2007 13:16:51 +0100
From: Corinna Vinschen <corinna-cygwin AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: cygwin makes shared folders on vista
Message-ID: <20071123121651.GQ30894@calimero.vinschen.de>
Reply-To: cygwin AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
References: <12429132 DOT post AT talk DOT nabble DOT com> <13177791 DOT post AT talk DOT nabble DOT com> <470FDEB8 DOT CAA832C2 AT dessent DOT net> <13187930 DOT post AT talk DOT nabble DOT com> <13854517 DOT post AT talk DOT nabble DOT com>
MIME-Version: 1.0
In-Reply-To: <13854517.post@talk.nabble.com>
User-Agent: Mutt/1.5.16 (2007-06-09)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Nov 20 02:51, E.Baud wrote:
> nmehta wrote:
> > Also, if you create a directory in Cygwin on /c like you did it does not
> > show up as shared.  If you create a directory in your Vista home directory
> > (/c/Users/<username>/) on the other hand it shows up as shared.  
> > ...
> > I can also say that CYGWIN=notntsec does fix this behavior (created
> > folders are no longer shared). 
> 
> Same thing for me: it depends on the current directory... subdirectories of
> Desktop have also these unexpected shared files/directories generated.
> 
> Setting this variable CYGWIN=notntsec (with .bashrc or Vista system
> environment variables)  is functioning well. No shared tags anymore when
> creating files/dir from cygwin shell.

I missed this crucial fact so far.  Now I was able to reproduce it.

It appears that the "shared" tag has nothing to do with sharing in a
network sharing sense.  The "shared" tag attached to files and directories
in your Vista home folder indicates that this file or folder has
permissions which allow a "normal" local user other than yourself to
access this file or directory.

Experimenting with various permission settings, I found that the
"shared" tag only shows up if the file/dir has any combination of ACEs
for the Users group or for Everyone, regardless of the actual
permissions granted in the ACE.

Apparently this is some sort of "security" consideration new in Vista.

Given that, there's nothing Cygwin can do about it.  POSIX permissions
require to have settings for Everyone and, depending on the /etc/passwd
settings, the Users group.  I'm certainly not going to cripple Cygwin's
POSIX permission facility just so that Vista doesn't show this weird
"shared" tag.

There are a couple of ways to go ahead, in the order from good to bad:

- Find out if there's a way to switch off this crappy Vista feature and
  switch it off.

- Move your Cygwin home directory outside of the C:/Users tree.  There's
  no reason to keep the Cygwin home directory in this tree.  I'm using
  C:/cygwin/home/corinna and/or C:/home/corinna for years and I haven't
  had any problems due to that.

- Set CYGWIN=nontsec and lose POSIX permissions.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019