lines added to /usr/share/vim/vimfiles/archlinux.vim?
I found this was just added to /usr/share/vim/vimfiles/archlinux.vim
" Move the swap file location to protect against CVE-2017-1000382
silent !install -d -m 700 ~/.vim/swap/ 2>&1 > /dev/null
shelling out while vim is loading does not seem like a great idea. https://www.reddit.com/r/vim/comments/805zvt/exiting_vim_leaves_a_huge_gap_in_my_terminal/
It is particularly annoying because one cannot override archlinux.vim.
Does anyone know who added this and how it addresses the CVE?
About this post
- Posted
- Archived
- Score
- 20 · 100% up
- Kind
- Text
- ID
- 807wuy
8 comments
Is this why vim started complaining at me starting yesterday or so?
not sure, what was it complaining about?
E303: Unable to open swap file for ".zshrc", recovery impossibleIt does this for any file I open with vim, and there are no vim swap files in the pwd.
EDIT: Except for
~/.swp, but removing doesn't change anything.EDIT 2: Turns out root somehow became the owner of ~/.vim/swap; vim running with user permissions could never get it. Solution was just to remove/rename the file.
This has a snippet at the end where it only shells out if the swap dir doesn't exist, which seems fairly obvious. It addresses the CVE by placing swap files in a dir that's only readable by the editing user.
Thanks- I think that snippet is more reasonable ; reported: https://bugs.archlinux.org/task/57640
FYI: The terminal-blanking bug was fixed today in 8.0.1542-2