From unknown Mon Jun 23 23:49:16 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#5826 <5826@debbugs.gnu.org> To: bug#5826 <5826@debbugs.gnu.org> Subject: Status: [feature] chmod +S to setgid directories alike +X Reply-To: bug#5826 <5826@debbugs.gnu.org> Date: Tue, 24 Jun 2025 06:49:16 +0000 retitle 5826 [feature] chmod +S to setgid directories alike +X reassign 5826 coreutils submitter 5826 Micha=C5=82 G=C3=B3rny severity 5826 wishlist tag 5826 wontfix thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 03 07:27:18 2010 Received: (at submit) by debbugs.gnu.org; 3 Apr 2010 11:27:18 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny1VV-0007sz-Gi for submit@debbugs.gnu.org; Sat, 03 Apr 2010 07:27:18 -0400 Received: from mx10.gnu.org ([199.232.76.166]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny19V-0007kA-91 for submit@debbugs.gnu.org; Sat, 03 Apr 2010 07:04:34 -0400 Received: from lists.gnu.org ([199.232.76.165]:47893) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Ny19P-0007DG-SR for submit@debbugs.gnu.org; Sat, 03 Apr 2010 07:04:27 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Ny19P-0001hc-Ir for bug-coreutils@gnu.org; Sat, 03 Apr 2010 07:04:27 -0400 Received: from [140.186.70.92] (port=52110 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Ny19N-0001gN-W3 for bug-coreutils@gnu.org; Sat, 03 Apr 2010 07:04:26 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.0 (2010-01-18) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE autolearn=unavailable version=3.3.0 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Ny19M-0004W6-FK for bug-coreutils@gnu.org; Sat, 03 Apr 2010 07:04:25 -0400 Received: from mail-bw0-f214.google.com ([209.85.218.214]:41368) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny19M-0004Vr-5m for bug-coreutils@gnu.org; Sat, 03 Apr 2010 07:04:24 -0400 Received: by bwz6 with SMTP id 6so1588664bwz.33 for ; Sat, 03 Apr 2010 04:04:21 -0700 (PDT) Received: by 10.204.45.207 with SMTP id g15mr4031526bkf.210.1270292661152; Sat, 03 Apr 2010 04:04:21 -0700 (PDT) Received: from pomiot.lan (213-238-102-37.adsl.inetia.pl [213.238.102.37]) by mx.google.com with ESMTPS id 14sm4897104bwz.10.2010.04.03.04.04.20 (version=SSLv3 cipher=RC4-MD5); Sat, 03 Apr 2010 04:04:20 -0700 (PDT) Date: Sat, 3 Apr 2010 13:04:25 +0200 From: =?UTF-8?B?TWljaGHFgiBHw7Nybnk=?= To: bug-coreutils@gnu.org Subject: [feature] chmod +S to setgid directories alike +X Message-ID: <20100403130425.3fbe7060@pomiot.lan> X-Mailer: Claws Mail 3.7.5 (GTK+ 2.18.9; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sat, 03 Apr 2010 07:27:17 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.4 (-----) Hello, I would really appreciate if chmod supported setting setgid permissions on directories (and files already having such) recursively, much like '+X' does set executable permission. To match the '+X' one, I suggest using '+S' for that. --=20 Best regards, Micha=C5=82 G=C3=B3rny From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 03 10:26:24 2010 Received: (at 5826) by debbugs.gnu.org; 3 Apr 2010 14:26:24 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny4Iq-00011O-7h for submit@debbugs.gnu.org; Sat, 03 Apr 2010 10:26:24 -0400 Received: from mail-out.m-online.net ([212.18.0.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny4Io-00011A-9y for 5826@debbugs.gnu.org; Sat, 03 Apr 2010 10:26:23 -0400 Received: from mail01.m-online.net (mail.m-online.net [192.168.3.149]) by mail-out.m-online.net (Postfix) with ESMTP id BA6D71C001D9; Sat, 3 Apr 2010 16:26:16 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.8.164]) by mail.m-online.net (Postfix) with ESMTP id 810859033A; Sat, 3 Apr 2010 16:26:16 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.3.149]) by localhost (dynscan1.mnet-online.de [192.168.8.164]) (amavisd-new, port 10024) with ESMTP id BSwt-+ew2npy; Sat, 3 Apr 2010 16:26:15 +0200 (CEST) Received: from igel.home (ppp-88-217-114-71.dynamic.mnet-online.de [88.217.114.71]) by mail.mnet-online.de (Postfix) with ESMTP; Sat, 3 Apr 2010 16:26:15 +0200 (CEST) Received: by igel.home (Postfix, from userid 501) id 4E7F1CA29C; Sat, 3 Apr 2010 16:26:15 +0200 (CEST) From: Andreas Schwab To: =?utf-8?B?TWljaGHFgiBHw7Nybnk=?= Subject: Re: bug#5826: [feature] chmod +S to setgid directories alike +X References: <20100403130425.3fbe7060@pomiot.lan> X-Yow: I've got to get these SNACK CAKES to NEWARK by DAWN!! Date: Sat, 03 Apr 2010 16:26:15 +0200 In-Reply-To: <20100403130425.3fbe7060@pomiot.lan> (=?utf-8?Q?=22Micha?= =?utf-8?Q?=C5=82_G=C3=B3rny=22's?= message of "Sat, 3 Apr 2010 13:04:25 +0200") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.95 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -3.3 (---) X-Debbugs-Envelope-To: 5826 Cc: 5826@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.8 (---) Micha=C5=82 G=C3=B3rny writes: > I would really appreciate if chmod supported setting setgid permissions > on directories (and files already having such) recursively, much like > '+X' does set executable permission. To match the '+X' one, I suggest > using '+S' for that. Since there is only a single setgid bit (unlike the exec bits) I don't see the point of +S (it looks like a no-op). Moreover, anything more complex than what chmod already provides can easily be accomplished with find. Andreas. --=20 Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint =3D 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED= 5 "And now for something completely different." From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 03 15:56:53 2010 Received: (at control) by debbugs.gnu.org; 3 Apr 2010 19:56:53 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny9Sf-00055K-CW for submit@debbugs.gnu.org; Sat, 03 Apr 2010 15:56:53 -0400 Received: from joseki.proulx.com ([216.17.153.58]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny9Sd-00055F-Sh for control@debbugs.gnu.org; Sat, 03 Apr 2010 15:56:52 -0400 Received: from dementia.proulx.com (dementia.proulx.com [192.168.230.115]) by joseki.proulx.com (Postfix) with ESMTP id 21EF6213FC for ; Sat, 3 Apr 2010 13:56:47 -0600 (MDT) Received: by dementia.proulx.com (Postfix, from userid 1000) id 095EE3CC204; Sat, 3 Apr 2010 13:56:47 -0600 (MDT) Date: Sat, 3 Apr 2010 13:56:47 -0600 From: Bob Proulx To: control@debbugs.gnu.org Subject: additional tagging Message-ID: <20100403195647.GA5362@dementia.proulx.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.4 (---) severity 5826 wishlist tag 5826 wontfix thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Apr 03 15:58:05 2010 Received: (at 5826-done) by debbugs.gnu.org; 3 Apr 2010 19:58:05 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny9Tp-00056T-Jh for submit@debbugs.gnu.org; Sat, 03 Apr 2010 15:58:05 -0400 Received: from joseki.proulx.com ([216.17.153.58]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ny9To-000568-68 for 5826-done@debbugs.gnu.org; Sat, 03 Apr 2010 15:58:04 -0400 Received: from dementia.proulx.com (dementia.proulx.com [192.168.230.115]) by joseki.proulx.com (Postfix) with ESMTP id A1EF7213FC; Sat, 3 Apr 2010 13:57:59 -0600 (MDT) Received: by dementia.proulx.com (Postfix, from userid 1000) id 9BE333CC204; Sat, 3 Apr 2010 13:57:59 -0600 (MDT) Date: Sat, 3 Apr 2010 13:57:59 -0600 From: Bob Proulx To: =?utf-8?B?TWljaGHFgiBHw7Nybnk=?= Subject: Re: bug#5826: [feature] chmod +S to setgid directories alike +X Message-ID: <20100403195759.GA505@dementia.proulx.com> References: <20100403130425.3fbe7060@pomiot.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20100403130425.3fbe7060@pomiot.lan> User-Agent: Mutt/1.5.18 (2008-05-17) Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.1 (--) X-Debbugs-Envelope-To: 5826-done Cc: 5826-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.2 (---) Micha=C5=82 G=C3=B3rny wrote: > I would really appreciate if chmod supported setting setgid permissions > on directories (and files already having such) recursively, much like > '+X' does set executable permission. To match the '+X' one, I suggest > using '+S' for that. I suggest using 'find' for this. And there is an advantage to using a standard command. It works anywhere. $ find . -type d -exec chmod g+s {} + Also the setgid bit isn't like the execute bit. They can't be directly compared. There are three execute bits. The +X implements a not completely trivial control flow. If the file is a directory OR if the file already had the user execute bit or the group execute bit or the other execute bit set. It is the three execute bits that makes it non-trivial and the usefulness of the +X mode. But by contrast setting the setgid bit is very simple. Just set it. It is only one bit. Plus there are security ramifications to think about when setting the setgid bit on files. And the decisions are operating system dependent. On most systems scripts should never be suid/sgid. And even on systems where it is safe to do so I don't think setting the suid/sgid bit on normal executables is something that should be done lightly. Bob From unknown Mon Jun 23 23:49:16 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Sun, 02 May 2010 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator