All vulnerabilities

Servers and applications

CVE-2021-3156

Sudo before 1.9.5p2 contains an off-by-one error that can result in a heap-based buffer overflow, which allows privilege escalation to root via "sudoedit -s" and a command-line argument that ends with a single backslash character.

Actively exploited: CISA added it to its Known Exploited Vulnerabilities catalog on 6 Apr 2022.

Severity
High 7.8
Published
26 Jan 2021
Last changed
17 Jun 2026
Added to UpHeron
1 Nov 2026
Fixed in
1.8.32, 1.9.5
Sources
NVD

Affected software

SoftwareAffected versions
sudoServers and applications · cpe:a:sudo_project:sudo
  • From 1.8.2 before 1.8.32
  • From 1.9.0 before 1.9.5
  • Version 1.9.5
  • Version 1.9.5-patch1

Known exploited

CISA name
Sudo Heap-Based Buffer Overflow Vulnerability
Required action
Apply updates per vendor instructions.
Due for US agencies
27 Apr 2022
Used in ransomware
Not known

References

  • NVD https://nvd.nist.gov/vuln/detail/CVE-2021-3156
  • CVE.org https://www.cve.org/CVERecord?id=CVE-2021-3156