X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org Message-ID: <48BD7B38.3000704@cygwin.com> Date: Tue, 02 Sep 2008 13:43:20 -0400 From: "Larry Hall (Cygwin)" Reply-To: cygwin AT cygwin DOT com User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.3) Gecko/20070505 Remi/2.0.0.0-3.fc4.remi Lightning/0.8 Thunderbird/2.0.0.0 Mnenhy/0.7.5.0 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: file attributes: cygwin (ls, chmod, chown, chgrp) versus XP References: <090320080759 DOT 8940 DOT 48BE43F8000BD0D4000022EC22230703729B0A02D29B9B0EBF000401999D040A0E080C0703 AT att DOT net> In-Reply-To: <090320080759.8940.48BE43F8000BD0D4000022EC22230703729B0A02D29B9B0EBF000401999D040A0E080C0703@att.net> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 Michael R. Wolf wrote: > I'm very familiar with the Unix filesystem, and the commands to change > and display attributes. I've been using cygwin for years, but have yet > to understand the XP permissions and how they correlate to how cygwin and > XP tools manipulate attributes. > > > I've noticed that the ls(1) output is different if I create a file with a > cygwin utility or with an XP utility. Specifically: > 1. What does the "+" mean in the 11th column after the standard 1-column type > and 9-column permission fields? > 2. Why are default permissions different if the file > is created with cygwin and XP? I understand that cywing will try to > create them with 666, modulated by the umask of 0022, yeilding a default > of 644, but how the heck does XP come up with "700+" (my interpretation > of "rwx------+")? '+' means there are permissions that don't "fit" into the traditional user/ group/others categories. Windows uses ACLs. Use 'getfacl', 'setfacl', and/or 'cacls' to access them. > -rw-r--r-- 1 michael 0 Sep 3 00:33 created_by_bash_io_redirect > -rwx------+ 1 michael 18 Sep 3 00:32 created_by_emacs > -rwx------+ 1 michael 17 Sep 3 00:31 created_by_notepad > -rw-r--r-- 1 michael 0 Sep 3 00:31 created_by_touch > > In addition, I can't get group information to show up in ls(1) output. You mean the name? Do you have a '/etc/group' file? Does it have your current groups in it? If not, (re)generate it with 'mkgroup -l [-d]' (or whichever options make the most sense in your environment). > The -G flag to suppress it has no effect, and seems to always be active. WJFFM. > It seems like these would be an important topics to reference in the > ls(1) and chmod(1) man pages, and also in the (seemingly outdated) > documentation of File Permissions > (http://cygwin.com/cygwin-ug-net/ntsec.html#ntsec-files). As for the UG, perhaps is more to your liking? I'd recommend reading the entire NT security section and reading up in the MSDN on the NT(FS) security model. This should answer allot of questions for you (and probably generate some new ones. ;-) ) > Have there been significatnt changes to cygwin since NT to accomodate XP? > I don't even know if the NT and XP filesystems are similar enough that I > can rely on documentation that discusses NT vs cygwin. All Windows platforms since W2K are NT-based (NT 3.x and 4.x are other previous NT-based platforms). You can assume that when the documentation refers to NT, it's referring to current Windows operating systems. As for file-systems, there are multiple options here. I believe you're implying that you're interested in NTFS-formatted file-systems. Everything I said about the documentation and NT holds true for NTFS. -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 216 Dalton Rd. (508) 893-9889 - FAX Holliston, MA 01746 _____________________________________________________________________ A: Yes. > Q: Are you sure? >> A: Because it reverses the logical flow of conversation. >>> Q: Why is top posting annoying in email? -- 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/