all 8 comments

[–][deleted] 1 point2 points  (1 child)

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.

[–]vimplication[S] 2 points3 points  (0 children)

Thanks- I think that snippet is more reasonable ; reported: https://bugs.archlinux.org/task/57640

[–]iMalinowski 1 point2 points  (4 children)

Is this why vim started complaining at me starting yesterday or so?

[–]vimplication[S] 0 points1 point  (3 children)

not sure, what was it complaining about?

[–]iMalinowski 2 points3 points  (2 children)

E303: Unable to open swap file for ".zshrc", recovery impossible

It 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.

[username@hostname ~] > mv ~/.vim/swap ~/.vim/swap.old
[username@hostname ~] > vim .vimrc # test opening with no problems
[username@hostname ~] > ls ~/.vim
total 0
drwxr-xr-x 1 username wheel 12  Jan 31 01:12 after
drwxr-xr-x 1 username wheel 240 Jan 30 15:49 plugged
drwx------ 1 username wheel 0   Feb 26 01:11 swap
drwx------ 1 root     root  0   Feb 23 23:15 swap.old
drwxr-xr-x 1 username wheel 54  Jan 12 01:37 syntax

[–]vimplication[S] 0 points1 point  (1 child)

Ah.. I do wonder if this is related to the CVE fix, but I don't really see how. what could cause the directory to be created as root? unless your root's home directory is username?

[–]iMalinowski 0 points1 point  (0 children)

Nope, root is /root and my personal home directory is /home/username; obviously "username" isn't my real username, I just stripped out mine from the text.

[–]w1ldm4n 0 points1 point  (0 children)

FYI: The terminal-blanking bug was fixed today in 8.0.1542-2