From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs,gmane.emacs.pretest.bugs Subject: bug#865: 23.0.60; The directory is unsafe today Date: Thu, 04 Sep 2008 23:11:10 -0400 Message-ID: References: <48BD642C.5050405@gmail.com> <48BD74D5.4050800@gnu.org> <48BDD155.8060005@gnu.org> <48BF2171.8040101@gnu.org> <48BF5671.1040705@gnu.org> Reply-To: Stefan Monnier , 865@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1220585269 23786 80.91.229.12 (5 Sep 2008 03:27:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 5 Sep 2008 03:27:49 +0000 (UTC) Cc: emacs-pretest-bug@gnu.org, 865@emacsbugs.donarmstrong.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Sep 05 05:28:44 2008 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1KbS02-0008AJ-4M for geb-bug-gnu-emacs@m.gmane.org; Fri, 05 Sep 2008 05:28:42 +0200 Original-Received: from localhost ([127.0.0.1]:55566 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KbRz2-00023m-I3 for geb-bug-gnu-emacs@m.gmane.org; Thu, 04 Sep 2008 23:27:40 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KbRyy-000221-JP for bug-gnu-emacs@gnu.org; Thu, 04 Sep 2008 23:27:36 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KbRyw-0001xL-Fb for bug-gnu-emacs@gnu.org; Thu, 04 Sep 2008 23:27:35 -0400 Original-Received: from [199.232.76.173] (port=43600 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KbRyw-0001wc-4c for bug-gnu-emacs@gnu.org; Thu, 04 Sep 2008 23:27:34 -0400 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:48881) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1KbRyv-00085k-Rb for bug-gnu-emacs@gnu.org; Thu, 04 Sep 2008 23:27:34 -0400 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m853RV3H028352; Thu, 4 Sep 2008 20:27:31 -0700 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id m853K4iU025432; Thu, 4 Sep 2008 20:20:04 -0700 X-Loop: don@donarmstrong.com Resent-From: Stefan Monnier Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Fri, 05 Sep 2008 03:20:04 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 865 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by submit@emacsbugs.donarmstrong.com id=B.122058428423192 (code B ref -1); Fri, 05 Sep 2008 03:20:04 +0000 Original-Received: (at submit) by emacsbugs.donarmstrong.com; 5 Sep 2008 03:11:24 +0000 Original-Received: from fencepost.gnu.org (fencepost.gnu.org [140.186.70.10]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id m853BKK9023177 for ; Thu, 4 Sep 2008 20:11:21 -0700 Original-Received: from mx10.gnu.org ([199.232.76.166]:46556) by fencepost.gnu.org with esmtp (Exim 4.67) (envelope-from ) id 1KbRhb-0003jv-OI for emacs-pretest-bug@gnu.org; Thu, 04 Sep 2008 23:09:39 -0400 Original-Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1KbRjA-0006JF-GC for emacs-pretest-bug@gnu.org; Thu, 04 Sep 2008 23:11:20 -0400 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.182]:4279) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KbRj5-0006In-Re; Thu, 04 Sep 2008 23:11:11 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AhoFAKs/wEhFxJRU/2dsb2JhbACBZbVWgWWBBg X-IronPort-AV: E=Sophos;i="4.32,320,1217822400"; d="scan'208";a="26376067" Original-Received: from 69-196-148-84.dsl.teksavvy.com (HELO ceviche.home) ([69.196.148.84]) by ironport2-out.teksavvy.com with ESMTP; 04 Sep 2008 23:11:10 -0400 Original-Received: by ceviche.home (Postfix, from userid 20848) id 7DA9AB405D; Thu, 4 Sep 2008 23:11:10 -0400 (EDT) In-Reply-To: (Eli Zaretskii's message of "Thu, 04 Sep 2008 19:10:51 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) X-detected-kernel: by monty-python.gnu.org: Genre and OS details not recognized. X-CrossAssassin-Score: 2 X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) Resent-Date: Thu, 04 Sep 2008 23:27:35 -0400 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:20177 gmane.emacs.pretest.bugs:22977 Archived-At: >> If we are going to attempt this, then it is better to tell a lie >> that fits with the expectations of POSIX (ie that owners of files >> are individual users). > The problem is, I don't see how we can do this reliably. In this > particular case, Emacs compares the file's ownership with the UID of > the user running Emacs, so we could pretend the file is owned by that > user. But in other cases, Emacs could compare the ownership to a UID > of some other user, and what will we do then? I think the problem comes earlier: the (let ((default-file-modes ?\700)) should make sure that the directory created there is owned by the use and not by some Administator group. Of course, on FAT there's just nothing we can do and the server-ensure-safe-dir functionality simply cannot be provided, so we should then just skip the safety checks, Stefan