Description
Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a double quote in a header parameter name is emitted into the generated request-validation zod.object({...}) schema without safe encoding. This permits attacker-controlled JavaScript to be evaluated when the generated zod schema module is imported, resulting in code execution in the developer, CI, test, or application environment. The affected code is packages/zod/src/index.ts and header request-validation generation. This issue is fixed in version 8.21.0.
Published: 2026-08-19
Score: 9.3 Critical
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

Orval generates type-safe JavaScript clients from OpenAPI specifications. Prior to release 8.21.0, a "double quote" in a header parameter name was inserted verbatim into a generated Zod validation schema. Because the schema is evaluated when the module is imported, the unescaped double quote allows attacker-controlled JavaScript to be injected and executed in the environment that imports the client. Based on the description, it is inferred that the vulnerability permits code injection when a malicious OpenAPI specification includes such a header name, leading to remote code execution with the privileges of the importing process.

Affected Systems

The issue affects the orval‑labs/orval JavaScript client generator package. Any installed version of orval older than 8.21.0 is vulnerable. The vulnerability is not limited to a single platform; it can impact development machines, continuous‑integration pipelines, test environments, or any application that imports the generated client code.

Risk and Exploitability

The CVSS score of 9.3 indicates a high‑severity remote code execution flaw. The EPSS score is not available, which suggests that, while the potential for exploitation exists, the public exploitation probability may be low due to the specialized nature of the tool. The vulnerability is not listed in the CISA KEV catalog. Based on the description, it is inferred that the likely attack vector is an attacker supplying a malicious OpenAPI specification containing a header parameter name with an unescaped double quote; the resulting generated Zod schema will execute arbitrary JavaScript when imported. The attack requires that the generated client code be imported in a Node or browser context, which is typical during development or continuous integration. Consequently, the overall risk to systems that use orval without upgrading is significant.

Generated by OpenCVE AI on August 20, 2026 at 13:13 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade orval to version 8.21.0 or newer to apply the fixed code path that safely encodes header parameter names.
  • For projects that cannot immediately upgrade, preprocess any OpenAPI specification to remove or escape double quotes in header parameter names before feeding them to orval, or manually edit the generated schema to encode the property keys.
  • If the generated client must be imported before patching, consider running the import in a minimal sandbox or separate process with restricted privileges, and disable header validation if it is safe in that context.
  • Review all CI and test pipelines that import generated clients for potential execution of user-supplied code, and monitor logs for signs of unexpected JavaScript execution.

Generated by OpenCVE AI on August 20, 2026 at 13:13 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-6437-gxhq-pqv8 Orval: Import-time RCE via header parameter name -> computed-property-key injection in the zod client
History

Tue, 25 Aug 2026 03:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'poc', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Wed, 19 Aug 2026 18:45:00 +0000

Type Values Removed Values Added
First Time appeared Orval-labs
Orval-labs orval
Vendors & Products Orval-labs
Orval-labs orval

Wed, 19 Aug 2026 17:45:00 +0000

Type Values Removed Values Added
Description Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a double quote in a header parameter name is emitted into the generated request-validation zod.object({...}) schema without safe encoding. This permits attacker-controlled JavaScript to be evaluated when the generated zod schema module is imported, resulting in code execution in the developer, CI, test, or application environment. The affected code is packages/zod/src/index.ts and header request-validation generation. This issue is fixed in version 8.21.0.
Title Orval: Import-time RCE via header parameter name -> computed-property-key injection in the zod client
Weaknesses CWE-116
CWE-94
CWE-95
References
Metrics cvssV4_0

{'score': 9.3, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N'}


Subscriptions

Orval-labs Orval
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-08-25T02:21:34.265Z

Reserved: 2026-08-07T18:26:53.524Z

Link: CVE-2026-71864

cve-icon Vulnrichment

Updated: 2026-08-25T02:21:28.416Z

cve-icon NVD

Status : Received

Published: 2026-08-19T18:17:23.313

Modified: 2026-08-25T03:16:56.380

Link: CVE-2026-71864

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-08-20T13:15:03Z

Weaknesses
  • CWE-116

    Improper Encoding or Escaping of Output

  • CWE-94

    Improper Control of Generation of Code ('Code Injection')

  • CWE-95

    Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')