all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Paul Eggert <eggert@cs.ucla.edu>
To: Katsumi Yamaoka <yamaoka@jpl.org>, Ken Brown <kbrown@cornell.edu>
Cc: emacs-devel@gnu.org
Subject: Re: master 739593d 3/5: Make gnus-copy-file act like copy-file etc.
Date: Tue, 12 Sep 2017 12:22:24 -0700	[thread overview]
Message-ID: <83fa9922-8d83-9d2f-82af-f34e90521d88@cs.ucla.edu> (raw)
In-Reply-To: <b4mr2vczlva.fsf@jpl.org>

[-- Attachment #1: Type: text/plain, Size: 1377 bytes --]

On 09/11/2017 07:33 PM, Katsumi Yamaoka wrote:
> But it might have to be documented in also the Gnus manual, as
> `gnus-summary-save-article' that uses the function doesn't
> specify a destination and a user has to enter the directory name.

The special behavior with gnus-summary-save-article and directories (or 
directory names) was not documented. Although I'm not a Gnus expert I 
took a stab at documenting the current behavior by installing the 
attached patch. If we revert the Gnus change (or make further changes) 
then this part of the manual will need to be revisited.

> IMHO, reverting the change would be better.

Does file name completion (TAB) cause '/' to be appended to the 
destination directory when you're using Gnus to save files? That should 
reduce the problem, though I admit it does not eliminate it.

The change was prompted by security concerns where attackers can hijack 
your data by planting symlinks at the wrong time in shared areas under 
/tmp and suchlike. We could complicate Emacs somewhat to make it more 
backwards-compatible in common cases such as yours; Eli is suggesting 
something along these lines. The tradeoff between convenience and 
security and maintainability is not obvious, though, and I worry that 
the suggestion as-is will reintroduce security problems for interactive 
users. Perhaps we can think of something better.


[-- Attachment #2: 0001-Tweak-Gnus-doc-re-gnus-copy-file.patch --]
[-- Type: text/x-patch, Size: 1117 bytes --]

From f5671c9c2d20e538f0f0eeaffbb37e592b2d232a Mon Sep 17 00:00:00 2001
From: Paul Eggert <eggert@cs.ucla.edu>
Date: Tue, 12 Sep 2017 12:15:22 -0700
Subject: [PATCH] Tweak Gnus doc re gnus-copy-file

* doc/misc/gnus.texi (Saving Articles):
Document behavior with directory name targets (Bug#27986).
Problem reported by Katsumi Yamaoka in:
http://lists.gnu.org/archive/html/emacs-devel/2017-09/msg00216.html
---
 doc/misc/gnus.texi | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi
index 3e9b48ec65..b002f5dea7 100644
--- a/doc/misc/gnus.texi
+++ b/doc/misc/gnus.texi
@@ -7759,7 +7759,9 @@ Saving Articles
 approach (uudecoding, unsharing) you should use @code{gnus-uu}
 (@pxref{Decoding Articles}).
 
-For the commands listed here, the target is a file.  If you want to
+For the commands listed here, the target is a file.
+A directory name (ending in @samp{/}) causes the target
+to be a file under that directory.  If you want to
 save to a group, see the @kbd{B c} (@code{gnus-summary-copy-article})
 command (@pxref{Mail Group Commands}).
 
-- 
2.13.5


  reply	other threads:[~2017-09-12 19:22 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20170911053128.28763.28434@vcs0.savannah.gnu.org>
     [not found] ` <20170911053130.C5F002068F@vcs0.savannah.gnu.org>
2017-09-11 23:14   ` master 739593d 3/5: Make gnus-copy-file act like copy-file etc Katsumi Yamaoka
2017-09-12  2:12     ` Ken Brown
2017-09-12  2:33       ` Katsumi Yamaoka
2017-09-12 19:22         ` Paul Eggert [this message]
2017-09-14  4:17           ` Stefan Monnier
2017-09-14 16:54             ` Eli Zaretskii
2017-09-14 17:59               ` Paul Eggert
2017-09-14 18:38                 ` Eli Zaretskii
2017-09-15  4:04                   ` Paul Eggert
2017-09-15  9:16                     ` Eli Zaretskii
2017-09-12  2:42       ` Eli Zaretskii
2017-09-13 19:33     ` Lars Ingebrigtsen
2017-09-13 20:07       ` Paul Eggert
2017-09-13 20:11         ` Lars Ingebrigtsen
2017-09-13 20:41           ` Paul Eggert
2017-09-13 21:10             ` Lars Ingebrigtsen
2017-09-13 23:32               ` Paul Eggert
2017-09-14 11:25                 ` Lars Ingebrigtsen
2017-09-14  2:35         ` Eli Zaretskii

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83fa9922-8d83-9d2f-82af-f34e90521d88@cs.ucla.edu \
    --to=eggert@cs.ucla.edu \
    --cc=emacs-devel@gnu.org \
    --cc=kbrown@cornell.edu \
    --cc=yamaoka@jpl.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.