# CVE-2026-28207: Zen-C Vulnerable to Command Injection via Malicious Output Filename

- Severity: Medium 6.6 (CVSS:3.1, scored by GitHub_M) `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:L`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 1.06%, higher than 65% of CVEs (2026-12-01)
- Public exploit code or proof of concept: 2 links below, marked "exploit"
- Published: 2026-02-26T22:17:58.898Z
- Modified: 2026-06-17T10:28:19.953Z
- Weaknesses: CWE-78
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

Zen C is a systems programming language that compiles to human-readable GNU C/C11. Prior to version 0.4.2, a command injection vulnerability (CWE-78) in the Zen C compiler allows local attackers to execute arbitrary shell commands by providing a specially crafted output filename via the `-o` command-line argument. The vulnerability existed in the `main` application logic (specifically in `src/main.c`), where the compiler constructed a shell command string to invoke the backend C compiler. This command string was built by concatenating various arguments, including the user-controlled output filename, and was subsequently executed using the `system()` function. Because `system()` invokes a shell to parse and execute the command, shell metacharacters within the output filename were interpreted by the shell, leading to arbitrary command execution. An attacker who can influence the command-line arguments passed to the `zc` compiler (like through a build script or a CI/CD pipeline configuration) can execute arbitrary commands with the privileges of the user running the compiler. The vulnerability has been fixed in version 0.4.2 by removing `system()` calls, implementing `ArgList`, and internal argument handling. Users are advised to update to Zen C version v0.4.2 or later.

(As written by CVE List.)

## Affected

- z-libs Zen-C: < 0.4.2
- zenc-lang zen_c: before 0.4.2

## Every score

- GitHub_M: CVSS:3.1 6.6 Medium `CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:L`
- NVD: CVSS:3.1 7.3 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H`

## References

- <https://github.com/z-libs/Zen-C/security/advisories/GHSA-9rff-x96h-76h2> (exploit, mitigation, vendor-advisory)
- <https://f0nduesav0yarde.github.io/blog/vulnerabilities/cve-2026-28207/> (exploit, third-party-advisory)

## Sources

- CVE List: [CVE-2026-28207](https://www.cve.org/CVERecord?id=CVE-2026-28207), CVE Terms of Use, modified 2026-03-02
- NVD: [CVE-2026-28207](https://nvd.nist.gov/vuln/detail/CVE-2026-28207), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2026-28207 · Whole record: https://cve.day/CVE-2026-28207.json · Rebuilt by cve.day 2026-11-25T22:59:14.982Z
