all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Pedro Moreira <pedro.moreira@ipbeja.pt>
To: 39563@debbugs.gnu.org
Subject: bug#39563: temp files
Date: Tue, 11 Feb 2020 11:32:56 +0000	[thread overview]
Message-ID: <eb9fe5a7-cb4b-1433-3b04-3992edad717a@ipbeja.pt> (raw)

Hello!

if a user edits a php file using emacs directly at the webserver, emacs 
automatically saves a temp file at the same location, for example the 
user opens index.php, emacs stores a copy index.php~.

Therefore the code in that file is exposed. If an attacker tries to 
access files like https://domain.com/index.php~ the server wont 
interpret that file as php and presents it as plain text exposing the 
source code.

I know this could be resolved with webserver configuration. But it is a 
problem i just discovered and leaves me very unconfortable using emacs.

Maybe should be better the temp file beying stored like index~.php or 
index.bck.php.

Thanks






             reply	other threads:[~2020-02-11 11:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-11 11:32 Pedro Moreira [this message]
2020-02-11 15:08 ` bug#39563: temp files Andreas Schwab
2020-02-11 15:15 ` Dmitry Gutov
2020-02-11 16:51 ` Corwin Brust
2021-08-30  1:22 ` bug#39563: default location of backup files Lars Ingebrigtsen

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=eb9fe5a7-cb4b-1433-3b04-3992edad717a@ipbeja.pt \
    --to=pedro.moreira@ipbeja.pt \
    --cc=39563@debbugs.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 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.