What’s Vulnerable › Vulnerabilities
CVE-2020-5210: NetHack command line -w option parsing is subject to a buffer overflow
- Severity: high (CVSS 7.8 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.8% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2020-01-28 · updated 2026-06-17
- Weakness: CWE-120
Description
In NetHack before 3.6.5, an invalid argument to the -w command line option can cause a buffer overflow resulting in a crash or remote code execution/privilege escalation. This vulnerability affects systems that have NetHack installed suid/sgid and shared systems that allow users to influence command line options. Users should upgrade to NetHack 3.6.5.
Affected products
- NetHack: before 3.6.5 — fixed in 3.6.5
How to fix
Upgrade to a fixed version: NetHack 3.6.5. Check the vendor advisory for mitigations.
References
- https://github.com/NetHack/NetHack/commit/f3def5c0b999478da2d0a8f0b6a7c370a2065f77
- https://github.com/NetHack/NetHack/security/advisories/GHSA-v5pg-hpjg-9rpp
- https://github.com/NetHack/NetHack/commit/f3def5c0b999478da2d0a8f0b6a7c370a2065f77
- https://github.com/NetHack/NetHack/security/advisories/GHSA-v5pg-hpjg-9rpp
Get alerted when CVE-2020-5210 or the next vulnerability affects your stack