Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 636186 (CVE-2017-1000382) - app-editors/vim: umask is ignored when creating a swap file
Summary: app-editors/vim: umask is ignored when creating a swap file
Alias: CVE-2017-1000382
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All Linux
: Normal minor (vote)
Assignee: Gentoo Security
Whiteboard: B4 [noglsa cve]
Depends on:
Reported: 2017-11-01 19:00 UTC by Aleksandr Wagner (Kivak)
Modified: 2018-04-08 21:37 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Aleksandr Wagner (Kivak) 2017-11-01 19:00:55 UTC
CVE-2017-1000382 (

VIM version 8.0.1187 (and other versions most likely) ignores umask when creating a swap file ("[ORIGINAL_FILENAME].swp") resulting in files that may be world readable or otherwise accessible in ways not intended by the user running the vi binary.


@ Maintainer(s): Please confirm which versions are vulnerable in the tree.

Note: It seems no official patches have been released yet.
Comment 1 Aaron Bauman Gentoo Infrastructure gentoo-dev Security 2018-04-08 21:17:16 UTC
This amounts to user hardening and upstream is probably not going to address it as it would break things.  Additionally, web servers should be hardened to combat such issues.
Comment 2 Larry the Git Cow gentoo-dev 2018-04-08 21:37:03 UTC
The bug has been referenced in the following commit(s):

commit 80c7123e4565333a0005c01e7f0dd570fbd39d8a
Author:     Patrice Clement <>
AuthorDate: 2018-04-08 21:36:19 +0000
Commit:     Patrice Clement <>
CommitDate: 2018-04-08 21:36:54 +0000

    app-editors/gvim: remove vulnerable versions.
    Package-Manager: Portage-2.3.24, Repoman-2.3.6

 app-editors/gvim/Manifest             |   3 -
 app-editors/gvim/gvim-8.0.0386.ebuild | 407 ----------------------------------
 app-editors/gvim/gvim-8.0.1188.ebuild | 371 -------------------------------
 3 files changed, 781 deletions(-)}