1
0
Fork 0
mirror of https://github.com/vim/vim synced 2025-03-22 17:55:10 +01:00
Commit graph

15 commits

Author SHA1 Message Date
Christian Brabandt
7e501f4d99
runtime(gzip): load undofile if there exists one
fixes: 
closes: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
2024-11-26 15:10:33 +01:00
D. Ben Knoble
cd8a3eaf53
runtime(dist): centralize safe executable check and add vim library ()
Follow up to 816fbcc26 (patch 9.0.1833: [security] runtime file fixes,
2023-08-31) and f7ac0ef50 (runtime: don't execute external commands when
loading ftplugins, 2023-09-06).

This puts the logic for safe executable checks in a single place, by introducing
a central vim library, so all filetypes benefit from consistency.

Notable changes:
- dist#vim because the (autoload) namespace for a new runtime support
  library. Supporting functions should get documentation. It might make
  life easier for NeoVim devs to make the documentation a new file
  rather than cram it into existing files, though we may want
  cross-references to it somewhere…
- The gzip and zip plugins need to be opted into by enabling execution
  of those programs (or the global plugin_exec). This needs
  documentation or discussion.
- This fixes a bug in the zig plugin: code setting s:tmp_cwd was removed
  in f7ac0ef50 (runtime: don't execute external commands when loading
  ftplugins, 2023-09-06), but the variable was still referenced. Since
  the new function takes care of that automatically, the variable is no
  longer needed.

Signed-off-by: D. Ben Knoble <ben.knoble+github@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-11-04 10:11:17 +01:00
Anton Sharonov
67c951df4c
runtime(ftplugin): allow to exec if curdir is in PATH
In case the current directory is present as valid $PATH entry, it is OK
to call the program from it, even if vim curdir is in that same
directory.

(Without that patch, for instance, you will not be able to open .zip
files while your current directory is /bin)

closes: 

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-09-05 21:04:44 +02:00
Christian Brabandt
816fbcc262
patch 9.0.1833: [security] runtime file fixes
Problem:  runtime files may execute code in current dir
Solution: only execute, if not run from current directory

The perl, zig and ruby filetype plugins and the zip and gzip autoload
plugins may try to load malicious executable files from the current
working directory.  This is especially a problem on windows, where the
current directory is implicitly in your $PATH and windows may even run a
file with the extension `.bat` because of $PATHEXT.

So make sure that we are not trying to execute a file from the current
directory. If this would be the case, error out (for the zip and gzip)
plugins or silently do not run those commands (for the ftplugins).

This assumes, that only the current working directory is bad. For all
other directories, it is assumed that those directories were
intentionally set to the $PATH by the user.

Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-08-31 23:52:30 +02:00
Christian Brabandt
e978b4534a
Farewell to Bram and dedicate upcoming Vim 9.1 to him ()
* Dedicate upcoming Vim 9.1 to Bram

Also replace in a few more places Brams email address and mention new
maintainers.

* Remove Bram from any Maintainer role

* runtime: Align Header

* it's mailing list not mailinglist
2023-08-13 10:33:05 +02:00
Bram Moolenaar
2ec618c9fe Updated runtime files. 2016-10-01 14:47:05 +02:00
Bram Moolenaar
32efaf6154 Update runtime files. 2014-11-05 17:02:17 +01:00
Bram Moolenaar
c236c16d08 updated for version 7.2b-000 2008-07-13 17:41:49 +00:00
Bram Moolenaar
c24dca26ac updated for version 7.1-305 2008-05-29 20:41:57 +00:00
Bram Moolenaar
c1762ccb6f updated for version 7.1b 2007-05-10 16:56:30 +00:00
Bram Moolenaar
5c5b0941ca updated for version 7.1a 2007-05-06 12:07:59 +00:00
Bram Moolenaar
60a495f02e updated for version 7.0-111 2006-10-03 12:44:42 +00:00
Bram Moolenaar
c4c25bfd12 updated for version 7.0-048 2006-08-08 17:53:03 +00:00
Bram Moolenaar
910f66f90c updated for version 7.0c10 2006-04-05 20:41:53 +00:00
Bram Moolenaar
87e25fdf80 updated for version 7.0117 2005-07-27 21:13:01 +00:00