Subject: Bug#4059: public readable editor-backups in pine

From: Winfried Truemper <[email-masked]>
Date: Tue, 6 Aug 1996 17:44:48 +0200 (MET DST)

Package: pine
Version: 3.94-2

Here what happens when I write e-mail:

-rw-r--r--   1 truemper students      169 Aug  6 17:37 #pico19247#

Whatever the hell this file is, it shouldn't be public accessible
because it contains what I write inside pine.

-Winfried

---

From: Dale Scheetz <[email-masked]>
Date: Tue, 6 Aug 1996 13:02:09 -0400 (EDT)

> because it contains what I write inside pine.
I can't reproduce this on my machine. Where is this file appearing? You
might check the permissions on the directory where it is being placed
(that usually defines the permissions of files written in that directory).
Also, if you have changed your pine configuration in any way, I need to
see your .pinerc file. (Send me this stuff in private e-mail)

Thanks,

Dwarf

------------                                          --------------

aka   Dale Scheetz                   Phone:   1 (904) 877-0257
      Flexible Software              Fax:     NONE 
      Black Creek Critters           e-mail:  [email-masked]

------------ If you don't see what you want, just ask --------------

---

From: Guy Maor <[email-masked]>
Date: Wed, 7 Aug 1996 10:36:55 -0500 (CDT)

> -rw-r--r--   1 truemper students      169 Aug  6 17:37 #pico19247#

That's emacs's autosave file.  emacs will copy the permissions of the
original file to set the autosave file.  For a new file, it will use
your umask.

Since this will happen on any editor that creates autosave files, one
solution would be for pine to create the file with permissions 600 and
then call emacs on it.  Just set your pine editor to "pineedit" which
would be a shell script like this:

#!/bin/sh
touch $1
chmod 600 $1
exec emacsclient $1

Instead of just having pine launch emacsclient directly.  You can
probably put a hook in the file load to do this also if you wish.

Guy