emacs/lisp/url
Paul Eggert 9d626dffc6 Add 'nofollow' flag to set-file-modes etc.
This avoids some race conditions (Bug#39683).  E.g., if some other
program changes a file to a symlink between the time Emacs creates
the file and the time it changes the file’s permissions, using the
new flag prevents Emacs from inadvertently changing the
permissions of a victim in some completely unrelated directory.
* admin/merge-gnulib (GNULIB_MODULES): Add fchmodat.
* doc/lispref/files.texi (Testing Accessibility, Changing Files):
* doc/lispref/os.texi (File Notifications):
* etc/NEWS:
Adjust documentation accordingly.
* lib/chmodat.c, lib/fchmodat.c, lib/lchmod.c, m4/fchmodat.m4:
* m4/lchmod.m4: New files, copied from Gnulib.
* lib/gnulib.mk.in: Regenerate.
* lisp/dired-aux.el (dired-do-chmod):
* lisp/doc-view.el (doc-view-make-safe-dir):
* lisp/emacs-lisp/autoload.el (autoload--save-buffer):
* lisp/emacs-lisp/bytecomp.el (byte-compile-file):
* lisp/eshell/em-pred.el (eshell-pred-file-mode):
* lisp/files.el (backup-buffer-copy, copy-directory):
* lisp/gnus/mail-source.el (mail-source-movemail):
* lisp/gnus/mm-decode.el (mm-display-external):
* lisp/gnus/nnmail.el (nnmail-write-region):
* lisp/net/tramp-adb.el (tramp-adb-handle-file-local-copy)
(tramp-adb-handle-write-region):
* lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-directly):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-write-region):
* lisp/net/tramp.el (tramp-handle-write-region)
(tramp-make-tramp-temp-file):
* lisp/server.el (server-ensure-safe-dir):
* lisp/url/url-util.el (url-make-private-file):
When getting or setting file modes, avoid following symbolic links
when the file is not supposed to be a symbolic link.
* lisp/doc-view.el (doc-view-make-safe-dir):
Omit no-longer-needed separate symlink test.
* lisp/gnus/gnus-util.el (gnus-set-file-modes):
* lisp/net/tramp.el (tramp-handle-file-modes):
* lisp/net/tramp-gvfs.el (tramp-gvfs-handle-set-file-modes):
* src/fileio.c (symlink_nofollow_flag): New function.
(Ffile_modes, Fset_file_modes):
Support an optional FLAG arg.  All C callers changed.
* lisp/net/ange-ftp.el (ange-ftp-set-file-modes):
* lisp/net/tramp-adb.el (tramp-adb-handle-set-file-modes):
* lisp/net/tramp-sh.el (tramp-sh-handle-set-file-modes):
* lisp/net/tramp-smb.el (tramp-smb-handle-set-file-modes):
* lisp/net/tramp-sudoedit.el (tramp-sudoedit-handle-set-file-modes):
Accept an optional FLAG arg that is currently ignored,
and add a FIXME comment for it.
* m4/gnulib-comp.m4: Regenerate.
2020-02-23 16:45:50 -08:00
..
ChangeLog.1 Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-about.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-auth.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-cache.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-cid.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-cookie.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-dav.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-dired.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-domsuf.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-expand.el Fix problem with degenerate <html base="."> specs in shr 2020-02-20 15:14:39 +01:00
url-file.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-ftp.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-future.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-gw.el Remove subsumed repetitions in regexps 2020-02-20 16:05:18 +01:00
url-handlers.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-history.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-http.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-imap.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-irc.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-ldap.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-mailto.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-methods.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-misc.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-news.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-nfs.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-parse.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-privacy.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-proxy.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-queue.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-tramp.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00
url-util.el Add 'nofollow' flag to set-file-modes etc. 2020-02-23 16:45:50 -08:00
url-vars.el Make more load-hooks obsolete 2020-01-16 23:06:04 -08:00
url.el Update copyright year to 2020 2020-01-01 00:59:52 +00:00