CVE-2026-50643 Out‑of‑Bounds Read in 8cc
An attacker can cause a denial of service in the 8cc compiler by providing maliciously crafted source files with invalid line directives.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Local or same network only
- Victim action needed
- Not needed
- Fix
- None listed
What is CVE-2026-50643?
CVE-2026-50643 is a medium-severity memory corruption vulnerability in rui314 8cc, published on 18 Jun 2026. It can only be exploited from the same machine or local network, with no action from the victim.
Official description
8cc is vulnerable to an Out‑of‑Bounds Read due to improper handling of #line directives and GNU linemarkers. The compiler accepts attacker-controlled filename and line number metadata and later uses it without validation when accessing source line arrays. By supplying invalid or oversized line numbers, an attacker can trigger out-of-bounds memory access and a crash.
Maintainer of this project was notified early about this vulnerability, but didn't respond with the details of vulnerability or vulnerable version range. Version corresponding to the commit b480958 was tested and confirmed as vulnerable, other versions were not tested but might also be vulnerable.
Weakness: CWE-125
Which versions are affected by CVE-2026-50643?
How do I fix CVE-2026-50643?
No fix has been published for CVE-2026-50643 yet. Limit exposure of the affected software until one is available.
Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.
Is CVE-2026-50643 being exploited?
There is no known exploitation of CVE-2026-50643 in the wild and no public exploit code.
Sources
Also known as GHSA-r8v3-j8rv-hmxv.