cve/2021/CVE-2021-3999.md

21 lines
1.0 KiB
Markdown
Raw Normal View History

2024-05-25 21:48:12 +02:00
### [CVE-2021-3999](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-3999)
![](https://img.shields.io/static/v1?label=Product&message=glibc&color=blue)
![](https://img.shields.io/static/v1?label=Version&message=%3D%20Fixed%20in%20glibc%20v2.31%20and%20above.%20&color=brighgreen)
![](https://img.shields.io/static/v1?label=Vulnerability&message=CWE-193%20-%20Off-by-one%20Error&color=brighgreen)
### 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.
### POC
#### Reference
- https://www.openwall.com/lists/oss-security/2022/01/24/4
#### Github
- https://github.com/ARPSyndicate/cvemon
- https://github.com/flexiondotorg/CNCF-02
- https://github.com/maxim12z/ECommerce
- https://github.com/rootameen/vulpine