CVE-2018-18955
In the Linux kernel 4.15.x through 4.19.x before 4.19.2, map_write() in kernel/user_namespace.c allows privilege escalation because it…
- 7.0HighCVSS base score
- 7.7%Exploitation in 30 daysEPSS · top 5.4% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- 7Public exploitsMetasploit, Nuclei and Exploit-DB
Description
In the Linux kernel 4.15.x through 4.19.x before 4.19.2, map_write() in kernel/user_namespace.c allows privilege escalation because it mishandles nested user namespaces with more than 5 UID or GID ranges. A user who has CAP_SYS_ADMIN in an affected user namespace can bypass access controls on resources outside the namespace, as demonstrated by reading /etc/shadow. This occurs because an ID transformation takes place properly for the namespaced-to-kernel direction but not for the kernel-to-namespaced direction.
Public exploit
An exploit or proof of concept is public: anyone can try it against an unpatched system. The public collections list a Metasploit module and 6 Exploit-DB entries for it. 2 references of the record are tagged as an exploit.
Show the exploits9
Metasploit modules1 module
- Linux Nested User Namespace idmap Limit Local Privilege Escalation (Metasploit module) (opens in a new tab)
exploit/linux/local/nested_namespace_idmap_limit_priv_escRank greatdisclosed 15 Nov 2018
Exploit-DB6 entries
- Linux Kernel 4.15.x < 4.19.2 - 'map_write() CAP_SYS_ADMIN' Local Privilege Escalation (dbus Method) (Exploit-DB entry) (opens in a new tab)
EDB-ID 47165local, linuxpublished 4 Jan 2019Not verified
- Linux Kernel 4.15.x < 4.19.2 - 'map_write() CAP_SYS_ADMIN' Local Privilege Escalation (polkit Method) (Exploit-DB entry) (opens in a new tab)
EDB-ID 47167local, linuxpublished 4 Jan 2019Not verified
- Linux - Nested User Namespace idmap Limit Local Privilege Escalation (Metasploit) (Exploit-DB entry) (opens in a new tab)
EDB-ID 45915local, linuxpublished 29 Nov 2018Verified
- Linux Kernel 4.15.x < 4.19.2 - 'map_write() CAP_SYS_ADMIN' Local Privilege Escalation (cron Method) (Exploit-DB entry) (opens in a new tab)
EDB-ID 47164local, linuxpublished 21 Nov 2018Not verified
- Linux Kernel 4.15.x < 4.19.2 - 'map_write() CAP_SYS_ADMIN' Local Privilege Escalation (ldpreload Method) (Exploit-DB entry) (opens in a new tab)
EDB-ID 47166local, linuxpublished 21 Nov 2018Not verified
- Linux - Broken uid/gid Mapping for Nested User Namespaces (Exploit-DB entry) (opens in a new tab)
EDB-ID 45886local, linuxpublished 16 Nov 2018Verified
References tagged exploit2 references
- 45915 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
- 45886 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
Modules, templates and exploits as listed by the Metasploit Framework (BSD-3-Clause), ProjectDiscovery's Nuclei templates (MIT) and the Exploit Database (GPLv2), read once a day. Where the data comes from
Timeline
ID reserved
By mitre
- 11 days later
· 11 days later
Published
- 6 years later
· 6 years later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| NVDNVD · Modified | 3.0 | High7.0 | CVSS:3.0/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 7.7% · top 5.4% of all CVEs (10 Nov 2026)
The list uses the assigner's score when there is one, then CISA's, then NVD's: High 7.0.
Affected products
n/a
- affected n/a
References
15
- https://github.com/torvalds/linux/commit/d2f007dbe7e4c9583eea6eb04d60001e85c6f1bd (opens in a new tab)x_refsource_MISCx_transferred
- https://cdn.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.18.19 (opens in a new tab)x_refsource_MISCx_transferred
- USN-3836-2 (opens in a new tab)vendor-advisoryx_refsource_UBUNTUx_transferred
- USN-3835-1 (opens in a new tab)vendor-advisoryx_refsource_UBUNTUx_transferred
- https://bugs.chromium.org/p/project-zero/issues/detail?id=1712 (opens in a new tab)x_refsource_MISCx_transferred
- http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=d2f007dbe7e4c9583eea6eb04d60001e85c6f1bd (opens in a new tab)x_refsource_MISCx_transferred
- USN-3833-1 (opens in a new tab)vendor-advisoryx_refsource_UBUNTUx_transferred
- USN-3832-1 (opens in a new tab)vendor-advisoryx_refsource_UBUNTUx_transferred
- 45915 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
- https://cdn.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.19.2 (opens in a new tab)x_refsource_MISCx_transferred
- 45886 (opens in a new tab)exploitx_refsource_EXPLOIT-DBx_transferred
- USN-3836-1 (opens in a new tab)vendor-advisoryx_refsource_UBUNTUx_transferred
- 105941 (opens in a new tab)vdb-entryx_refsource_BIDx_transferred
- https://support.f5.com/csp/article/K39103040 (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://security.netapp.com/advisory/ntap-20190416-0003/ (opens in a new tab)x_refsource_CONFIRMx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2018-10659 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisories (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2018-18955)Record last updated .