Home

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.

PUBLISHED Reserved 2026-06-05 | Published 2026-06-18 | Updated 2026-06-18 | Assigner CERT-PL




MEDIUM: 5.1CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N

Problem types

CWE-125 Out-of-bounds Read

Product status

Default status
unknown

b480958 (custom)
affected

Credits

Michal Majchrowicz (AFINE) finder

Marcin Wyczechowski (AFINE) finder

References

cert.pl/en/posts/2026/06/CVE-2026-50641 third-party-advisory

github.com/rui314/8cc product

cve.org (CVE-2026-50643)

nvd.nist.gov (CVE-2026-50643)

Download JSON