From unknown Fri Jun 20 07:23:27 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#50191 <50191@debbugs.gnu.org> To: bug#50191 <50191@debbugs.gnu.org> Subject: Status: Dired's G, O, T should not follow symlinks Reply-To: bug#50191 <50191@debbugs.gnu.org> Date: Fri, 20 Jun 2025 14:23:27 +0000 retitle 50191 Dired's G, O, T should not follow symlinks reassign 50191 emacs submitter 50191 Paul Eggert severity 50191 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Aug 24 14:23:30 2021 Received: (at submit) by debbugs.gnu.org; 24 Aug 2021 18:23:30 +0000 Received: from localhost ([127.0.0.1]:45200 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIb58-0004xk-J9 for submit@debbugs.gnu.org; Tue, 24 Aug 2021 14:23:30 -0400 Received: from lists.gnu.org ([209.51.188.17]:34850) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mIb57-0004xd-Gz for submit@debbugs.gnu.org; Tue, 24 Aug 2021 14:23:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:46494) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mIb57-00015X-Ar for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 14:23:29 -0400 Received: from zimbra.cs.ucla.edu ([131.179.128.68]:45936) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mIb55-0000Nb-AG for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 14:23:28 -0400 Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id CBD4816005A for ; Tue, 24 Aug 2021 11:23:24 -0700 (PDT) Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id LKUQlkazElHU for ; Tue, 24 Aug 2021 11:23:24 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 2B98D1600BC for ; Tue, 24 Aug 2021 11:23:24 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id IsZXhcQXszJx for ; Tue, 24 Aug 2021 11:23:24 -0700 (PDT) Received: from [192.168.1.9] (cpe-172-91-119-151.socal.res.rr.com [172.91.119.151]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id 0CB1116005A for ; Tue, 24 Aug 2021 11:23:24 -0700 (PDT) To: Emacs bug reports and feature requests From: Paul Eggert Organization: UCLA Computer Science Department Subject: Dired's G, O, T should not follow symlinks Message-ID: <3628f993-24f4-8839-27ba-cf2025d1808e@cs.ucla.edu> Date: Tue, 24 Aug 2021 11:23:23 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=131.179.128.68; envelope-from=eggert@cs.ucla.edu; helo=zimbra.cs.ucla.edu X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) This follows up from Bug#11912. The Dired commands G (dired-do-chgrp), O (dired-do-chown) and T=20 (dired-do-touch) currently follow symbolic links. They should instead=20 act on the symlinks themselves, as dired-do-chmod does; this better=20 matches the visual experience of Dired. Not all platforms support modifying these symlink attributes but many=20 do, and Dired should support the ones that do, as it already does for=20 symlink permissions and the M command. Fixing this bug will also fix some security-relevant race-condition=20 bugs, where an attacker with write access to a shared nonsticky=20 directory can cause a Dired-using victim to chgrp, chown, and/or touch=20 arbitrary files accessible to the victim.