SecurityContext

CVE-2026-28207: Zen C - Command Injection

  • Cve: CVE-2026-28207
  • Name: Zen C - Command Injection
  • 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.
  • Impact: Local attackers can execute arbitrary shell commands with the privileges of the user running the compiler.
  • Remediation: Update to version 0.4.2 or later.
  • Vulnerability type: command_injection
  • Vulnerability impact: remote_code_execution
  • Requirement type: none
  • Labels source: projectdiscovery
  • Severity: high
  • Cvss score: 7.3
  • Cvss vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H
  • Epss score: 0.01064
  • Epss percentile: 0.65508
  • Assignee: [email protected]
  • Published at: 2026-02-26T23:16:35Z
  • Age in days: 271
  • Modified at: 2026-06-17T10:28:19Z
  • Patch available: yes
  • Public exploits total: 2
  • References total: 2
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-28207
  • Nvd status: analyzed
  • Checked, none or zero: known exploited entries, nuclei templates, public exploits capped, rejected by nvd
  • Not known: requirements, hackerone

Cwe

IdName
CWE-78Improper Neutralization of Special Elements used in an OS Command

Public exploits

UrlSourceAdded date
https://github.com/z-libs/Zen-C/security/advisories/GHSA-9rff-x96h-76h2nvd2026-02-26
https://f0nduesav0yarde.github.io/blog/vulnerabilities/cve-2026-28207/nvd2026-02-26

References

UrlSourceTags
https://github.com/z-libs/Zen-C/security/advisories/GHSA-9rff-x96h-76h2nvdExploit, Mitigation, Vendor Advisory
https://f0nduesav0yarde.github.io/blog/vulnerabilities/cve-2026-28207/nvdExploit, Third Party Advisory

Products

ProductAffectedPlatform boundSourcesUrl
zenc-lang:zen_c< 0.4.2nonvd/v1/products/zenc-lang/zen_c

Projects

RepositoryLink kindsIndexedUrl
z-libs/Zen-Cfix, security_advisoryyes/v1/repositories/z-libs/Zen-C

Index

  • Checked, none or zero: repositories, repositories high signal, packages

Exploitation

  • Public exploit: yes
  • Public exploit count: 2
  • Public exploit first date: 2026-02-26
  • Authentication required: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, initial access, remote
  • Not known: known exploited since, vulncheck known exploited since, nuclei template, initial access since, hackerone reports, exposed hosts