chmod g+s ineffective
Norton Allen
allen@huarp.harvard.edu
Mon Jul 11 16:49:01 GMT 2022
On 7/10/2022 10:33 PM, Eliot Moss wrote:
> On 7/10/2022 10:17 PM, Chris Wagner wrote:
>>>> On 6/29/2022 9:18 AM, Norton Allen wrote:
>>>>>>> On one machine I have, chmod g+s fails to set the sticky bit.
>>>>>>> The >>> command
>>>>>>> does not return any error, but ls -l continues to show the bit
>>>>>>> not set.
>>>>>>> $ mkdir foo
>>>>>>> $ chgrp flight foo
>>>>>>> $ chmod g+ws foo
>>>>>>> $ ls -ld foo
>>>>>>> drwxrwxr-x+ 1 nort flight 0 Jun 29 06:50 foo
>>
>> Hi. The permission bits are implemented as normal Window's DACLs
>> (Discretionary Access List). +s is implemented magically with the
>> NULL SID. You can view it from Explorer or with icacls. Try
>> checking the return code (echo $?) from chmod. Also try changing
>> perms from Explorer. You might not be able to set the NULL SID for
>> some reason.
>
> I'd like to add that, for good reason, the Cygwin DACLs do not conform
> to the order of entries that some Windows tools prefer. Don't let any
> Windows program/tool reorder the DACLs! It will break the Cygwin
> functionality, and the Cygwin order does not break Windows functionality.
>
Right. My experience (Windows 10) is that I cannot change perms from
Explorer if I don't let them reorder the perms (which I do not).
I have been separated from the machine that exhibits the problem, so I
have not been able to try the solutions suggested, but expect to have it
back in a week or so.
More information about the Cygwin
mailing list