emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Max Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: org-persist files in /tmp
Date: Thu, 22 Dec 2022 21:41:04 +0700	[thread overview]
Message-ID: <to1qgh$11lj$1@ciao.gmane.io> (raw)
In-Reply-To: <sdva63f4mxf.fsf@fw.net.yu>

On 22/12/2022 19:34, Ruijie Yu wrote:
> One possible approach to this is to have all org-persist related
> temporary directories into an overall "$TMPDIR/org-persist" directory.

Predictable name in a "world" writable directory generally is not a good 
idea. Multiple users may try to run Org on the same machine. There are 
some kernel parameters to prevent certain type of attacks, however I am 
unsure concerning their default values in various Linux distributions 
and what will happen if one user creates a symlink to somewhere the 
under home directory of another one. So unfortunately a directory 
reusable by different emacs sessions should be avoided.

Ihor, I do not like that after your latest changes temporary directory 
became world readable.

Another point is that creating temporary files and directories must be 
an atomic operation. In between of removing and recreating it an 
attacker might manage to create a file with the same name.



  reply	other threads:[~2022-12-22 14:45 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-21 13:18 org-persist files in /tmp Fraga, Eric
2022-12-21 15:06 ` Ihor Radchenko
2022-12-21 15:59   ` Fraga, Eric
2022-12-21 16:07     ` Ihor Radchenko
2022-12-21 17:18       ` William Denton
2022-12-21 18:45         ` Ihor Radchenko
2022-12-22  4:30   ` Greg Minshall
2022-12-22 12:34     ` Ruijie Yu via General discussions about Org-mode.
2022-12-22 14:41       ` Max Nikulin [this message]
2022-12-22 15:45         ` Tim Cross
2022-12-22 16:07           ` Max Nikulin
2022-12-23  6:35             ` tomas
2022-12-23 14:12               ` Max Nikulin
2022-12-23 15:19                 ` tomas
2022-12-25  9:32                 ` Ihor Radchenko
2022-12-25  9:30               ` Ihor Radchenko
2022-12-25 11:37                 ` tomas
2022-12-25  9:28         ` Ihor Radchenko
2022-12-25  9:25     ` Ihor Radchenko
2022-12-22  4:35   ` Tim Cross

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

  List information: https://www.orgmode.org/

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

  git send-email \
    --in-reply-to='to1qgh$11lj$1@ciao.gmane.io' \
    --to=manikulin@gmail.com \
    --cc=emacs-orgmode@gnu.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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).