From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#62260: 30.0.50; [PATCH] Restrict auto-save file mode Date: Sat, 18 Mar 2023 20:51:28 +0200 Message-ID: <83a609c2q7.fsf@gnu.org> References: <87v8iynl5c.fsf@ledu-giraud.fr> <83h6uiawvv.fsf@gnu.org> <87r0tlnbtz.fsf@ledu-giraud.fr> <83bkkpc2x6.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25724"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 62260@debbugs.gnu.org To: manuel@ledu-giraud.fr Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Mar 18 19:52:14 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pdbf3-0006V6-Vq for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 18 Mar 2023 19:52:14 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pdbev-0002Kh-S0; Sat, 18 Mar 2023 14:52:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdbes-0002KT-Tx for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2023 14:52:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pdbes-0002Ib-KP for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2023 14:52:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pdbes-0004Bq-GB for bug-gnu-emacs@gnu.org; Sat, 18 Mar 2023 14:52:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 18 Mar 2023 18:52:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62260 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 62260-submit@debbugs.gnu.org id=B62260.167916549116064 (code B ref 62260); Sat, 18 Mar 2023 18:52:02 +0000 Original-Received: (at 62260) by debbugs.gnu.org; 18 Mar 2023 18:51:31 +0000 Original-Received: from localhost ([127.0.0.1]:49081 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdbeN-0004B0-96 for submit@debbugs.gnu.org; Sat, 18 Mar 2023 14:51:31 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:58194) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pdbeL-0004Ao-J6 for 62260@debbugs.gnu.org; Sat, 18 Mar 2023 14:51:30 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdbeG-0002Du-Bj; Sat, 18 Mar 2023 14:51:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=UWF4RyW6JLicmiWInzcZ+Zkvlq/scCsoOhy2JvNNNQs=; b=dyi9axe8nsqP Y4Uz7WpbezHFYvPtMyLN4Egftl27hxQRb8mlZ7DccVsRQ4fr8lciSNl+GuzydYUpRFkLgGnSqb/us L4VgJgPP5AERKWJKPN87ndiNyXS1IwRFlM1EAZ14+/Po6fi3nyFnbwgf+KqCtTuW6+f9zO14wWjaQ rkSG5Z6UftcK2w+TAenNGw9I564LpUpoZJ2iRWNV/t+QM2qnvq2ZBpcrcVmta5mAyLByNKI36+qfy oHRg5pB17wljeu1FVwCIj71UuiDlDUqAm12L/N/lRjqm3dehZ6wYLbVZlTbHK/3Fsm1mphbiFqFtS U4k3xnbudRZ0wSlimK75wQ==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pdbeF-0001p1-Op; Sat, 18 Mar 2023 14:51:24 -0400 In-Reply-To: <83bkkpc2x6.fsf@gnu.org> (message from Eli Zaretskii on Sat, 18 Mar 2023 20:47:17 +0200) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:258209 Archived-At: > Cc: 62260@debbugs.gnu.org > Date: Sat, 18 Mar 2023 20:47:17 +0200 > From: Eli Zaretskii > > > From: Manuel Giraud > > Cc: 62260@debbugs.gnu.org > > Date: Sat, 18 Mar 2023 19:39:20 +0100 > > > > Eli Zaretskii writes: > > > > [...] > > > > > That could make it impossible to overwrite the auto-save file later. > > > So I don't think we should make this change. > > > > I've tried it but I'm not able to come with such an example. With this > > patch, the auto-save file has always a mode of 0600 even for a file with > > a mode of 0006 not own by me. > > Did you try a different user? Actually, the right question is: what exactly did you try? As you can see from the code, 0666 value is used only for buffers that don't visit files. Did you try with such a buffer, and what exactly did you try?