DMARC-Filter: OpenDMARC Filter v1.4.2 delorie.com 52TIFvHv917582 Authentication-Results: delorie.com; dmarc=pass (p=none dis=none) header.from=cygwin.com Authentication-Results: delorie.com; spf=pass smtp.mailfrom=cygwin.com DKIM-Filter: OpenDKIM Filter v2.11.0 delorie.com 52TIFvHv917582 Authentication-Results: delorie.com; dkim=pass (1024-bit key, unprotected) header.d=cygwin.com header.i=@cygwin.com header.a=rsa-sha256 header.s=default header.b=hkRwUJJv X-Recipient: archive-cygwin AT delorie DOT com DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D0D633856DE6 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com; s=default; t=1743272154; bh=peMj06k03iteGeBQ/RvpLBZcrExOqWDDz0eeBg5KN70=; h=Date:Subject:To:References:In-Reply-To:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=hkRwUJJvKxK+mjbmUSgr6v509s4ZrZYDeKYcevI6wNgUsoY86qTvXZ/l1yqz1cit4 Jx31QDA8wQ9ILvxyjqiYbYrpo8ld2cFgLw38mzE5QJLhB2m6RM4SYJCAUce+QPyCu4 6W7QAUtnwbKQ1syxLZiQyV0/uTP1YqV204947yk0= X-Original-To: cygwin AT cygwin DOT com Delivered-To: cygwin AT cygwin DOT com DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 948583858D1E ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 948583858D1E ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1743272095; cv=none; b=mQvOcEWygbmj0gJ895U8NiRA/k3M+RCj0br8TjITCgKCS+iZTLLsguvNtbppZ4/iQ3dwm4pzStGLlXIQAxSIx7z6GR+5GYYOjWYUZqRb90ADdSP+FipqIrQ8FxqDuOvQQZAXflxeXyut8lmrkndHG5xOQfUkItPxVv2yP3nGfII= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1743272095; c=relaxed/simple; bh=gDtasoz21CdDpPHgQznqhQyyGyf7v/TT6PxmRh2/SDA=; h=Message-ID:Date:MIME-Version:From:Subject:To:DKIM-Signature; b=L9F5bnXxv762ziyQa5vLSBfYTZnTdBUK97IWBj4IFk+8YBi9/lvC/lUp2D7SVsQD7RSi1a36M0BPcYER5s9DieId1o8mJiJn6m6CREzpDjQ1ynShQYjhX2I+Ox5mbEc7D9vK3l81bibPUvLVYgOoJK80Ou7DdJJ69X1y0PTIRWA= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 948583858D1E Message-ID: <622ba8e4-fd75-46c9-978d-760ccf6d7d45@SystematicSW.ab.ca> Date: Sat, 29 Mar 2025 12:14:51 -0600 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: symbolic link curiousity in 3.6.0 Content-Language: en-CA To: cygwin AT cygwin DOT com References: <7892953 DOT SKYDtnEIZr AT nimes> <2351191 DOT D4D8VRik6i AT nimes> Autocrypt: addr=Brian DOT Inglis AT SystematicSW DOT ab DOT ca; keydata= xjMEXopx8xYJKwYBBAHaRw8BAQdAnCK0qv/xwUCCZQoA9BHRYpstERrspfT0NkUWQVuoePbN LkJyaWFuIEluZ2xpcyA8QnJpYW4uSW5nbGlzQFN5c3RlbWF0aWNTdy5hYi5jYT7ClgQTFggA PhYhBMM5/lbU970GBS2bZB62lxu92I8YBQJeinHzAhsDBQkJZgGABQsJCAcCBhUKCQgLAgQW AgMBAh4BAheAAAoJEB62lxu92I8Y0ioBAI8xrggNxziAVmr+Xm6nnyjoujMqWcq3oEhlYGAO WacZAQDFtdDx2koSVSoOmfaOyRTbIWSf9/Cjai29060fsmdsDM44BF6KcfMSCisGAQQBl1UB BQEBB0Awv8kHI2PaEgViDqzbnoe8B9KMHoBZLS92HdC7ZPh8HQMBCAfCfgQYFggAJhYhBMM5 /lbU970GBS2bZB62lxu92I8YBQJeinHzAhsMBQkJZgGAAAoJEB62lxu92I8YZwUBAJw/74rF IyaSsGI7ewCdCy88Lce/kdwX7zGwid+f8NZ3AQC/ezTFFi5obXnyMxZJN464nPXiggtT9gN5 RSyTY8X+AQ== Organization: Systematic Software In-Reply-To: <2351191.D4D8VRik6i@nimes> X-Stat-Signature: 67sntxbuygseudpbfyfixhkc3ttamgcb X-Rspamd-Server: rspamout04 X-Rspamd-Queue-Id: 7D47B31 X-Session-Marker: 427269616E2E496E676C69734053797374656D6174696353572E61622E6361 X-Session-ID: U2FsdGVkX1+ZsP/0kzUJrN9SP7z3YwzB4Wk1hCn/I3k= X-HE-Tag: 1743272092-639448 X-HE-Meta: U2FsdGVkX18r62nAs40UYtwosGFbtakJ806JmM0GL+Ji+M289UOK9ZTlFDOyOrALj+RcTkVFmtiRZPkL3kEO3qe2o8RDiT/EVqkIXWcWeWqKEC5m+VR5xJLe18tZv3ykWdvXIzZt27LEy+skaxC/rwJMP2BEvQ6hq3Fax5jTYn9WBbioEgHUq+7fpQilGCw8p6nN12j2SyIzw7VVvUS+Xn1d/lG2ebAY2BiTfufMz4Vcr3wLV8M2dxYj+vG7nBnPXMMHDx8OCqblX/MA4B5ZoVGDnzh2idpH7huCCirVQj2zTCf/6y9/qbklMxXT6tAc1F20Ssg2x6D/5ECeRL79NgN9kqMjc7/6oUiu0k4QOzbGaRTtAojlDBktWoNzSJdop4O5pmwgpx3i3w7NDy7TGcwPnxknq92KqentlRr3mR8s6QC88/mEshjRuqH+IOBQ X-BeenThere: cygwin AT cygwin DOT com X-Mailman-Version: 2.1.30 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Brian Inglis via Cygwin Reply-To: cygwin AT cygwin DOT com Cc: Brian Inglis Content-Type: text/plain; charset="utf-8"; Format="flowed" Errors-To: cygwin-bounces~archive-cygwin=delorie DOT com AT cygwin DOT com Sender: "Cygwin" Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by delorie.com id 52TIFvHv917582 On 2025-03-29 08:02, Bruno Haible via Cygwin wrote: > Corinna Vinschen wrote: >>> Regarding what acl_extended_file() does, there is the man page by >>> Andreas Grünbacher: >>> https://www.kernel.org/doc/man-pages/online/pages/man3/acl_extended_file.3.html >>> Gnulib is not the only user of acl_extended_file(); therefore I would >>> suggest that Cygwin should follow that man page — regardless of Gnulib. >> >> It already does! The acl_extended_file() change for directories we just >> talked about will actually be a deviation from Andreas' man page. > > OK, then Cygwin's acl_extended_file should not change. > >>> An ACL implementation that shows a '+' sign on 99.9% of the files is >>> not useful. A user can't practically run 'getfacl' on all files and >>> understand the result. In other words, ACLs need to be the special case, >>> not the common case. >> >> Yeah, that's a good point. If the user is beaten with a stick with >> a '+' sign written on it, it's basically no help. > > Glad to have an agreement here. Then, gnulib won't change: it will not > use Cygwin's acl_extended_file() function and instead use the function > acl_access_nontrivial(), defined in Gnulib. > >> But your question was specificially about files created in the above >> dir: >> >> - Files created by a Cygwin process inside that dir will have only the >> usual three ACL entries constituting standard POSIX permission bits, >> combined with their umask, i.e.: >> >> $ cd /tmp/glo1FkFx/tmpdir0 >> $ umask >> 22 >> $ touch foo >> $ getfacl foo >> # file: foo >> # owner: corinna >> # group: vinschen >> user::rw- >> group::r-- >> other::r-- >> >> - Files created by non-Cygwin processes inside that dir will have by >> default(*) only the usual three ACL entries constituting standard >> POSIX permission bits, but there's no umask handling in the non-Cygwin >> process, i.e. >> >> $ cd /tmp/glo1FkFx/tmpdir0 >> $ cmd >> C:\cygwin64\tmp\glQatIoG\tmpdir0>echo foo > bar >> C:\cygwin64\tmp\glQatIoG\tmpdir0>exit >> $ getfacl bar >> # file: bar >> # owner: corinna >> # group: vinschen >> user::rwx >> group::r-x >> other::r-x >> >> (*) Most Windows processes rely entirely on the permissions in >> the ACLs and the Windows ACL inheritance rules. >> >> Does that answer your question? > > Thanks for explaining. This matches my earlier experiments on Cygwin; > see these comments in the acl_access_nontrivial function: > https://git.savannah.gnu.org/gitweb/?p=gnulib.git;a=blob;f=lib/acl-internal.c;h=6c50feacbb811da92da9a68d544132d87ad8dbf3;hb=HEAD#l80 > > So, in summary, I too see the action item (regarding the behaviour > of 'ls' on symlinks) more on the coreutils side. Please reiterate what you see needing to be patched in coreutils 9.6 - just your patch 0001-file-has-acl-port-symlink-code-to-Cygwin.patch or something else? Dogfooding coreutils 9.6 since release - now also under Cygwin 3.6 - permissions on build symlinks: $ uname -srvmo CYGWIN_NT-10.0-19045 3.6.0-1.x86_64 2025-03-18 17:01 UTC x86_64 Cygwin $ ls --version ls (GNU coreutils) 9.6 Packaged by Cygwin (9.6-1) Copyright (C) 2025 Free Software Foundation, Inc. ... $ lsp coreutils-9.6-1.x86_64/build/GNUmakefile # ls, getfacl, icacls -rw-r--r-- 1 $USER None 4589 Jan 17 07:46 .../build/GNUmakefile # file: coreutils-9.6-1.x86_64/build/GNUmakefile # owner: $USER # group: None user::rw- group::r-- other::r-- .../src/coreutils-9.6/GNUmakefile $HOSTNAME/$USER:(R,W,D,WDAC,WO) $HOSTNAME/None:(R) Everyone:(R) Successfully processed 1 files; Failed processing 0 files -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retrancher but when there is no more to cut -- Antoine de Saint-Exupéry -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple