Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm 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 Message-ID: <42772847.AE2315CB@dessent.net> Date: Tue, 03 May 2005 00:29:11 -0700 From: Brian Dessent MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: AW: 1.5.16-1: chmod problem References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Reply-To: cygwin AT cygwin DOT com "Pach Roman (GS-EC/ESA4) *" wrote: > Unfortunately the Windows has a special attribute 'write protection' > which can be set in the mask for file's attribute. > So there is a kind of conflict now. Despite I can't change file permissions (in the acl) > I can every time set/reset the bit 'write protection'. > I see, it is very interesting feature of the so called operating system. > There is the question at this place: > Should the implementation of chmod allow the setting/resetting of the 'write protection' bit > in spite of the missing permission 'change file permission' in the acl ? As far as I know, there are really three things that we're talking about: "Attributes" - Archive, Readonly, Hidden, and System - the legacy flags from ancient DOS. Requires the "Write Attributes" ACL bit to modify. "Extended Attributes" - hardly ever used: metadata, alternate streams (?). I think this was a crutch that was used on non-NTFS/HPFS disks in order to store metadata back when FAT was still common. Requires the "Write Extended Attributes" ACL bit to modify. "Permissions" - The full NTFS security entity aka ACL. Requires "Change Permissions" bit in order to modify. So in your case your permissions include the first two, but not the last. This means you should be able to set R/H/S/A at will. I'm at a loss as to why the R flag keeps getting set even though you keep clearing it, but it probably has something to do with SMB/CIFS. Brian -- 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/