CVE-2021-3156
High 7.8KEV · exploitedPublic exploit ×2Fix status unknownSudo Heap-Based Buffer Overflow Vulnerability
Record last updated
CVSS score
High on a 0 to 10 scale
EPSS, chance of exploitation in 30 days
Among the highest-scored CVEs. A prediction, not evidence.
CISA remediation deadline
Passed 1669 days ago for U.S. federal agencies
Description
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.
Weakness: CWE-122, CWE-193
Patching and mitigation
- Patch status
- Unknown: no source documents a fix
- Mitigation
- None documented
- Vendor guidance
- security.gentoo.org (opens in a new tab)
Affected products
| Vendor | Product | Affected versions | Fixed in | Per |
|---|---|---|---|---|
| Sudo | Sudo | Not documented | Not documented | CISA KEV |
Timeline
Disclosure
CVE record published by mitre
Source: CVE Program (opens in a new tab)
06 Apr 2022KEV
Added to the CISA Known Exploited Vulnerabilities catalog
Source: CISA KEV (opens in a new tab)
06 Apr 2022Exploitation
Exploitation confirmed by CISA KEV
Source: CISA KEV (opens in a new tab)
Vendor guidance and references
- FEDORA-2021-8840cbdccd (opens in a new tab)vendor-advisory, x_transferred
- FEDORA-2021-2cb63d912a (opens in a new tab)vendor-advisory, x_transferred
- GLSA-202101-33 (opens in a new tab)vendor-advisory, x_transferred
- 20210129 Sudo Privilege Escalation Vulnerability Affecting Cisco Products: January 2021 (opens in a new tab)vendor-advisory, x_transferred
- DSA-4839 (opens in a new tab)vendor-advisory, x_transferred
- 20210211 APPLE-SA-2021-02-09-1 macOS Big Sur 11.2.1, macOS Catalina 10.15.7 Supplemental Update, and macOS Mojave 10.14.6 Security Update 2021-002 (opens in a new tab)mailing-list, x_transferred
- 20210126 Baron Samedit: Heap-based buffer overflow in Sudo (CVE-2021-3156) (opens in a new tab)mailing-list, x_transferred
- 20240204 CVE-2023-6246: Heap-based buffer overflow in the glibc's syslog() (opens in a new tab)mailing-list
- [oss-security] 20210126 Baron Samedit: Heap-based buffer overflow in Sudo (CVE-2021-3156) (opens in a new tab)mailing-list, x_transferred
- [oss-security] 20210127 Re: Baron Samedit: Heap-based buffer overflow in Sudo (CVE-2021-3156) (opens in a new tab)mailing-list, x_transferred
- [oss-security] 20210127 Re: Baron Samedit: Heap-based buffer overflow in Sudo (CVE-2021-3156) (opens in a new tab)mailing-list, x_transferred
- [oss-security] 20210215 Re: sudo: Ineffective NO_ROOT_MAILER and Baron Samedit (opens in a new tab)mailing-list, x_transferred
- [oss-security] 20210914 Re: Oracle Solaris membership in the distros list (opens in a new tab)mailing-list
- [oss-security] 20240130 CVE-2023-6246: Heap-based buffer overflow in the glibc's syslog() (opens in a new tab)mailing-list
- [oss-security] 20240130 Re: CVE-2023-6246: Heap-based buffer overflow in the glibc's syslog() (opens in a new tab)mailing-list
- https://kc.mcafee.com/corporate/index?page=content&id=SB10348 (opens in a new tab)x_transferred
- [debian-lts-announce] 20210126 [SECURITY] [DLA 2534-1] sudo security update (opens in a new tab)mailing-list, x_transferred
- https://nvd.nist.gov/vuln/detail/CVE-2021-3156 (opens in a new tab)government
- https://security.netapp.com/advisory/ntap-20210128-0001/ (opens in a new tab)x_transferred
- https://security.netapp.com/advisory/ntap-20210128-0002/ (opens in a new tab)x_transferred
- https://support.apple.com/kb/HT212177 (opens in a new tab)x_transferred
- https://www.beyondtrust.com/blog/entry/security-advisory-privilege-management-for-unix-linux-pmul-basic-and-privilege-management-for-mac-pmm-affected-by-sudo-vulnerability (opens in a new tab)x_transferred
- VU#794544 (opens in a new tab)third-party-advisory, x_transferred
- https://www.openwall.com/lists/oss-security/2021/01/26/3 (opens in a new tab)x_transferred
- https://www.oracle.com//security-alerts/cpujul2021.html (opens in a new tab)x_transferred
- https://www.oracle.com/security-alerts/cpuapr2022.html (opens in a new tab)
- https://www.oracle.com/security-alerts/cpuoct2021.html (opens in a new tab)
- https://www.sudo.ws/stable.html (opens in a new tab)x_transferred
- https://www.synology.com/security/advisory/Synology_SA_21_02 (opens in a new tab)x_transferred
- https://www.vicarius.io/vsociety/posts/sudoedit-pwned-cve-2021-3156 (opens in a new tab)
Public exploit code
Exploit or proof-of-concept code is publicly available on Exploit-DB. Shown as a prioritization and defensive-testing signal — treat exploit code as hostile and run it only against systems you are authorized to test.
- Exploit-DB 49521 (opens in a new tab)2 entries on Exploit-DB