CVE-2021-3156Sudo
Heap-based buffer overflow in Sudo due to off-by-one error
High 7.8 KEV High EPSS
Follow: this CVE · Sudo · Sudo We alert you by email or Slack (account required).
- Priority
- 57
- CVSS 3.1
- 7.8
- EPSS
- 100.0% probability of exploitation in 30 days · percentile 100
- Auth required
- Yes
- In KEV since
- Apr 6, 2022
- CISA deadline
- Apr 27, 2022
- Ransomware use
- Unknown
- Published
- Jan 26, 2021
- Updated
- Jun 17, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-193
- SSVC (CISA)
- Exploitation: active · Automatable: no · Technical impact: total
- Vector
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
What happens
Sudo before 1.9.5p2 contains an off-by-one error allowing heap-based buffer overflow. An authenticated attacker can escalate privileges to root by running "sudoedit -s" with a command-line argument ending in a backslash. CISA confirmed this vulnerability as actively exploited.
Show the original NVD text
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.
Exploitation confirmed by CISA
Sudo contains an off-by-one error that can result in a heap-based buffer overflow, which allows for privilege escalation.
Action required by CISA: Apply updates per vendor instructions.
What to do
Patch available · fixed versions: 1.8.32, 1.9.5p2
Update Sudo to version 1.8.32, 1.9.5p2 or later depending on your version branch.
- Apply the vendor's security update for Sudo.
- CISA has confirmed it is exploited: treat it as urgent. The deadline for US federal agencies was April 27, 2022.
- Check logs for signs of earlier exploitation.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| sudo_project | sudo | ≥ 1.8.2 < 1.8.32 |
| sudo_project | sudo | ≥ 1.9.0 < 1.9.5 |
| sudo_project | sudo | 1.9.5 |
| sudo_project | sudo | 1.9.5 |
| fedoraproject | fedora | 32 |
| fedoraproject | fedora | 33 |
| debian | debian_linux | 9.0 |
| debian | debian_linux | 10.0 |
| netapp | active_iq_unified_manager | all |
| netapp | cloud_backup | all |
| netapp | hci_management_node | all |
| netapp | oncommand_unified_manager_core_package | all |
| netapp | ontap_select_deploy_administration_utility | all |
| netapp | ontap_tools | 9 |
| netapp | solidfire | all |
| mcafee | web_gateway | 8.2.17 |
| mcafee | web_gateway | 9.2.8 |
| mcafee | web_gateway | 10.0.4 |
| synology | diskstation_manager_unified_controller | 3.0 |
| synology | diskstation_manager | 6.2 |
| synology | skynas_firmware | all |
| synology | vs960hd_firmware | all |
| beyondtrust | privilege_management_for_mac | < 21.1.1 |
| beyondtrust | privilege_management_for_unix/linux | < 10.3.2-10 |
| oracle | micros_compact_workstation_3_firmware | 310 |
| oracle | micros_es400_firmware | ≥ 400 ≤ 410 |
| oracle | micros_kitchen_display_system_firmware | 210 |
| oracle | micros_workstation_5a_firmware | 5a |
| oracle | micros_workstation_6_firmware | ≥ 610 ≤ 655 |
| oracle | communications_performance_intelligence_center | ≥ 10.3.0.0.0 ≤ 10.3.0.2.1 |
| oracle | communications_performance_intelligence_center | ≥ 10.4.0.1.0 ≤ 10.4.0.3.1 |
| oracle | tekelec_platform_distribution | ≥ 7.4.0 ≤ 7.7.1 |
Official sources
References
Links published by the sources. Open them with care.
- packetstormsecurity.com Exploit Third Party Advisory VDB Entry
- packetstormsecurity.com Exploit Third Party Advisory VDB Entry
- packetstormsecurity.com Exploit Third Party Advisory VDB Entry
- packetstormsecurity.com Exploit Third Party Advisory VDB Entry
- packetstormsecurity.com Exploit Third Party Advisory VDB Entry
- seclists.org Mailing List Third Party Advisory
- seclists.org Exploit Mailing List Third Party Advisory
- seclists.org Exploit Mailing List Third Party Advisory
- www.openwall.com Exploit Mailing List Third Party Advisory
- www.openwall.com Mailing List Third Party Advisory
- www.openwall.com Mailing List Third Party Advisory
- www.openwall.com Exploit Mailing List Third Party Advisory
- www.openwall.com Mailing List Patch Third Party Advisory
- www.openwall.com Exploit Mailing List
- www.openwall.com Mailing List
- kc.mcafee.com Broken Link Third Party Advisory
- lists.debian.org Mailing List Third Party Advisory
- lists.fedoraproject.org Mailing List Release Notes
- lists.fedoraproject.org Mailing List Release Notes
- security.gentoo.org Third Party Advisory
- security.netapp.com Third Party Advisory
- security.netapp.com Third Party Advisory
- support.apple.com Third Party Advisory
- tools.cisco.com Third Party Advisory
- www.beyondtrust.com Third Party Advisory
- www.debian.org Third Party Advisory
- www.kb.cert.org Third Party Advisory US Government Resource
- www.openwall.com Exploit Mailing List Third Party Advisory
- www.oracle.com Patch Third Party Advisory
- www.oracle.com Patch Third Party Advisory
- www.oracle.com Patch Third Party Advisory
- www.sudo.ws Release Notes
- www.synology.com Third Party Advisory
- www.vicarius.io Exploit Third Party Advisory
- www.cisa.gov US Government Resource