From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from forward500o.mail.yandex.net (forward500o.mail.yandex.net [IPv6:2a02:6b8:0:1a2d::610]) by sourceware.org (Postfix) with ESMTPS id B53A8385C32E for ; Wed, 29 Jun 2022 12:50:03 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B53A8385C32E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=yandex.ru Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=yandex.ru Received: from sas1-8cb9eff5270f.qloud-c.yandex.net (sas1-8cb9eff5270f.qloud-c.yandex.net [IPv6:2a02:6b8:c14:449d:0:640:8cb9:eff5]) by forward500o.mail.yandex.net (Yandex) with ESMTP id C6797941CDD; Wed, 29 Jun 2022 15:50:01 +0300 (MSK) Received: from sas8-9a72d639b2ad.qloud-c.yandex.net (sas8-9a72d639b2ad.qloud-c.yandex.net [2a02:6b8:c1b:2904:0:640:9a72:d639]) by sas1-8cb9eff5270f.qloud-c.yandex.net (mxback/Yandex) with ESMTP id 0xGhj1O15C-o1fe2ewd; Wed, 29 Jun 2022 15:50:01 +0300 X-Yandex-Fwd: 2 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.ru; s=mail; t=1656507001; bh=vUTD9c7TdNfn6mT2XsOX4O9P3FlRuGVZRuF1BB+s7AY=; h=In-Reply-To:Subject:To:From:Message-ID:References:Date:Reply-To; b=EpxPffMaRnNnINzDKsjFfmqzleQdF4PYwUPI3+IEm2QZBUWsmFgaefI3FEDK3sJa2 7E9W89Gbvicr3Nd4i3vq1k4pS2Sq1f/f/3OXHPXJ+e5zYriq6tyEmDVBeHrLbBm52f 6+KortQ26n/m+2b4U9ZztcRgQ8iCNxL3fPYNYIf4= Authentication-Results: sas1-8cb9eff5270f.qloud-c.yandex.net; dkim=pass header.i=@yandex.ru Received: by sas8-9a72d639b2ad.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id IKAbWtdy4A-o0MKdMYE; Wed, 29 Jun 2022 15:50:00 +0300 (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client certificate not present) Received: from [192.168.1.10] (HELO daemon2.darkdragon.lan) by daemon2 (Office Mail Server 0.8.12 build 08053101) with SMTP; Wed, 29 Jun 2022 12:39:52 -0000 Date: Wed, 29 Jun 2022 15:39:52 +0300 From: Andrey Repin X-Mailer: The Bat! (v9.3.4) Professional Reply-To: cygwin@cygwin.com Message-ID: <792558531.20220629153952@yandex.ru> To: Norton Allen , cygwin@cygwin.com Subject: Re: chmod g+s ineffective In-Reply-To: <9c053381-4466-ea8a-11d6-ea2e676d3b35@huarp.harvard.edu> References: <9c053381-4466-ea8a-11d6-ea2e676d3b35@huarp.harvard.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, KAM_THEBAT, NICE_REPLY_A, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: cygwin@cygwin.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Cygwin discussions and problem reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Jun 2022 12:50:06 -0000 Greetings, Norton Allen! > 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 ----------------^ $ getfacl foo > I ran strace, and it looks like the correct system call parameter is getting passed. > I am curious as to how the sticky bit is implemented. First see if it was set or not. > It isn't obvious what underlying Windows functionality (if any) is applied. It does. But the big question is, where do you try to do that. If this is inside Cygwin installation root, then things could work more or less POSIX'y. If this is outside Cygwin root (f.e. in your system profile), it may or may not work completely, depends how did you mount /cygdrive prefix. > Ah, just checked on a system where this works, and creating a file in the > directory from the > command shell does not set the group, so presumably this functionality is > all within cygwin. That works for my application, except when it doesn't. > Any suggestions on what I should look for? Look if you could avoid using +s. Isn't DACL enough? -- With best regards, Andrey Repin Wednesday, June 29, 2022 15:36:50 Sorry for my terrible english...