X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Date: Mon, 25 Jan 2010 20:55:28 +0100 From: Corinna Vinschen To: cygwin AT cygwin DOT com Subject: Re: chmod and DOS vs POSIX paths Message-ID: <20100125195528.GR2402@calimero.vinschen.de> Reply-To: cygwin AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com References: <27307971 DOT post AT talk DOT nabble DOT com> <20100125160534 DOT GO2402 AT calimero DOT vinschen DOT de> <27312068 DOT post AT talk DOT nabble DOT com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <27312068.post@talk.nabble.com> User-Agent: Mutt/1.5.20 (2009-06-14) Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com http://cygwin.com/acronyms/#TOFU On Jan 25 11:25, brassrat wrote: > > I agree that the having an R/O attribute conflicts with the concept of ACLS; > however, it is not true that the chmod command does not change this flag. > For example, > if you chmod +w a file with the R/O flag 'set' the R/O flag is reset. > (maybe this is a side-effect of the ACL-based processing within windows?) No, it's deliberate. The R/O flag is in the way(*). It's not a concept known in POSIX and POSIX permissions are represented by matching ACEs much better. > so the current behavior is somewhat inconsistent, especially given that > chmod works differently depending upon whether it is 'given' a DOS or a > POSIX path. That's a side-effect of the DOS path handling. DOS paths are handled as noacl paths, as described in the User's Guide. Thus DOS paths are always handled same as FAT/FAT32 filesystems, even when pointing to NTFS. > from a cygwin/posix perspective, doesn't 'chmod a-w FILE' mean that the file > should not writable? and doesn't setting the 'r/o flag' (if supported by the > underlying file system) capture this concept better than some combination of > acl entries? No. If you look into the ACEs representing the POSIX permissions you'll see why. Corinna (*) For instance, it breaks admin backup/restore permissions and requires special handling in calls to open(2). -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Project Co-Leader cygwin AT cygwin DOT com Red Hat -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple