CVE-2021-3999A flaw was found in glibc. An off-by-one buffer overflow and underflow in getcwd() may lead to memory corruption when the size of the…
- 7.8HighCVSS base score
- 0.81%Exploitation in 30 daysEPSS · top 42% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
A flaw was found in glibc. An off-by-one buffer overflow and underflow in getcwd() may lead to memory corruption when the size of the buffer is exactly 1. A local attacker who can control the input buffer and size passed to getcwd() in a setuid program could use this flaw to potentially execute arbitrary code and escalate their privileges on the system.
Timeline
ID reserved
By redhat
- 9 months later
· 9 months later
Published
- 4 years later
· 4 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 |
|---|---|---|---|
| CISA-ADPADP (enrichment) | 3.1 | High7.8 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVDNVD · Modified | 3.1 | High7.8 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 0.81% · top 42% of all CVEs (18 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: total
The list uses the assigner's score when there is one, then CISA's, then NVD's: High 7.8.
Affected products
glibc
- affected Fixed in glibc v2.31 and above.
References
References10
- https://www.openwall.com/lists/oss-security/2022/01/24/4 (opens in a new tab)x_transferred
- https://sourceware.org/bugzilla/show_bug.cgi?id=28769 (opens in a new tab)x_transferred
- https://sourceware.org/git/gitweb.cgi?p=glibc.git%3Bh=23e0e8f5f1fb5ed150253d986ecccdc90c2dcd5e (opens in a new tab)x_transferred
- https://bugzilla.redhat.com/show_bug.cgi?id=2024637 (opens in a new tab)x_transferred
- https://access.redhat.com/security/cve/CVE-2021-3999 (opens in a new tab)x_transferred
- https://security-tracker.debian.org/tracker/CVE-2021-3999 (opens in a new tab)x_transferred
- [debian-lts-announce] 20221017 [SECURITY] [DLA 3152-1] glibc security update (opens in a new tab)mailing-listx_transferred
- https://security.netapp.com/advisory/ntap-20221104-0001/ (opens in a new tab)x_transferred
- https://cert-portal.siemens.com/productcert/html/ssa-831302.html (opens in a new tab)
- https://cert-portal.siemens.com/productcert/html/ssa-398330.html (opens in a new tab)
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-2021-27189 (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-2021-3999)Record last updated .