Skip to main content

Orval EUVDEUVD-2026-62604

| CVE-2026-71865 CRITICAL
Code Injection (CWE-94)
2026-08-19 GitHub_M GHSA-653q-5476-x79g
9.3
CVSS 4.0 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Craft malicious OpenAPI spec with quoted query-param name
  2. Delivery
    Victim runs Orval zod codegen
  3. Exploit
    Unescaped key injected into zod.object schema
  4. Execution
    Generated module imported at build/test/runtime
  5. Impact
    Arbitrary code executes in dev/CI environment

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Code injection prevention, sandbox exec
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Initial Access

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Requires that the victim run Orval (version < 8.21.0) with the zod validation/client generation target against an OpenAPI v3 or Swagger v2 spec whose query-parameter name contains a double-quote character plus attacker JavaScript, AND that the resulting generated zod schema module then be imported or executed (which normally happens during build, test, or app startup). Exploitation is therefore gated on the attacker controlling or tampering with the spec input and on the zod generation path being used; it does not affect consumers who never regenerate clients or who only use non-zod outputs. Limiting factors: attacker must influence the spec source, the developer/CI must actually invoke codegen and load the generated file, and only pre-8.21.0 versions are vulnerable - these are what bound the real-world exposure below the raw 9.3 score.

Impact

The vendor CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H, score 9.3) treats this as network-reachable, low-complexity, unauthenticated, high-impact code execution. That framing is optimistic for a build-time codegen flaw: exploitation is not a live network service hit but requires the victim to run Orval against an attacker-influenced OpenAPI spec and then import the generated zod module, which realistically implies some user/pipeline interaction rather than true zero-touch remote exploitation. No EPSS probability was supplied and the CVE is not in CISA KEV, so there is no evidence of active or widespread exploitation; the danger is concentrated in supply-chain scenarios where specs come from third-party or untrusted sources. Impact if triggered is genuinely severe (arbitrary code execution in a developer or CI context, a high-value pivot point), so this warrants prompt patching despite the absence of KEV/EPSS signals - treat it as a real, high-severity supply-chain risk rather than a routine high-CVSS-low-real-risk item.

Exploit ScenarioDerived

An attacker publishes or tampers with an OpenAPI spec so that a query parameter is named with an embedded double quote and JavaScript payload; a developer or CI pipeline generates a zod client from that spec with Orval, and as soon as the generated validation module is imported the injected code runs with the developer's or build agent's privileges. Because the payload executes at import time in the build/test environment, it can exfiltrate CI secrets or poison downstream artifacts. The vendor's fix commit includes tests firing payloads like require('child_process').execSync('id'), demonstrating the vector even though no in-the-wild exploit is documented.

Act Now Prioritize within 24-48h. Why: CRITICAL severity + public POC available.
Patch available 0.5% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 19, 2026

Code injection in Orval before 8.21.0 lets an attacker-controlled OpenAPI v3 / Swagger v2 specification achieve arbitrary code execution: a double-quote character in a query parameter name is written verbatim into the generated request-validation zod.object({...}) schema, so importing that generated module evaluates embedded JavaScript. Any developer workstation, CI runner, test harness, or application that generates a zod client from a malicious or tampered spec is affected. There is no public exploit identified at time of analysis, but the vendor's own fix commit ships tests demonstrating payloads such as require('fs').execSync('id'); it is not listed in CISA KEV and no EPSS score was provided.

RemediationAI

Vendor-released patch: 8.21.0 - upgrade the orval dev dependency to 8.21.0 or later (release notes: https://github.com/orval-labs/orval/releases/tag/v8.21.0; advisory: https://github.com/orval-labs/orval/security/advisories/GHSA-653q-5476-x79g; fix in PR https://github.com/orval-labs/orval/pull/3692 and commit 8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6). Until you can upgrade, do not run Orval codegen against OpenAPI/Swagger specs from untrusted or externally-controlled sources, and treat any spec fetched over the network as untrusted; if you must, review the generated zod schema files for suspicious content before importing them and run codegen in an isolated, unprivileged sandbox (container or ephemeral CI job with no secrets) so injected code cannot reach credentials - the trade-off is added pipeline friction and manual review overhead. As a source-side control, validate/reject parameter names containing quote or backslash characters in your spec-linting step before it reaches Orval.

Affected VersionsENISA

orval < 8.21.0

Affected Packages

npm orval fix: 8.21.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in npm

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Orval is a TypeScript code generator that turns OpenAPI/Swagger specifications into type-safe HTTP clients, including optional zod runtime-validation schemas produced by the packages/zod generator. The root cause is CWE-94 (Improper Control of Generation of Code): the object-key emitter in packages/core/src/getters/keys.ts wrapped non-identifier keys in single quotes but did not escape their contents, so a query-parameter name lifted from the spec was placed directly into generated source. The CPE cpe:2.3:a:orval-labs:orval identifies the affected package. The fix (PR #3692, commit 8ef1bfd) introduces a jsStringLiteralEscape helper backed by the jsesc library so keys - and, per the related GHSA-88f2-fpv8-89q2 changes, server URLs and path segments - are safely escaped before being embedded as JS string/template literals.

Know when Orval gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 9.3 CRITICAL
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
vuln.today AI 8.8 HIGH

Spec is attacker-controllable over the network (AV:N) but the victim must run codegen and import the generated module (UI:R); no auth needed (PR:N) and arbitrary code execution yields full C/I/A impact.

3.1 AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
None
Vulnerable system: Confidentiality
High
Vulnerable system: Integrity
High
Vulnerable system: Availability
High
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

2
Patch available
Aug 19, 2026 - 18:03 EUVD
CVE Published
Aug 19, 2026 - 17:36 cve.org
CRITICAL 9.3

DescriptionCVE.org

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 query 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 query request-validation generation. This issue is fixed in version 8.21.0.

Executive ViewAI

Why It Matters

Orval, a developer tool used in application code generation, contains a critical vulnerability that allows attackers to execute arbitrary commands on developer workstations and build servers through malicious API specification files. This vulnerability affects the entire development infrastructure and supply chain, creating risk of source code theft, malware injection, and compromised software releases.

Business Impact: Severe
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.5%
Top 61% exploitable
Prevalence
Medium
popular TypeScript OpenAPI client/zod generator, common dev-tool footprint
Threat Intel
1
1 source
Exploit
POC
Public exploit code exists
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC Yes
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity + public POC available
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

66
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +46
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Code Injection CRITICAL

Code injection occurs when an application accepts user input and passes it directly into a language interpreter or evaluator without proper sanitization.

Remote Code Execution represents the critical moment when an attacker successfully runs arbitrary code on a target system without physical access.

More in Orval

View all
CVE-2026-22785 CRITICAL POC
9.8 Jan 12

orval (TypeScript API client generator) before 7.18.0 has code injection via OpenAPI specification summary fields in MCP

CVE-2026-72717 CRITICAL POC
9.3 Aug 19

Arbitrary code execution in Orval (orval-labs/orval) before 8.21.0 allows an attacker who controls an OpenAPI v3 or Swag

CVE-2026-72716 CRITICAL POC
9.3 Aug 19

Code injection in Orval before 8.21.0 lets an attacker-controlled OpenAPI v3 or Swagger v2 specification execute arbitra

CVE-2026-62681 CRITICAL POC
9.3 Aug 19

Code injection in Orval before 8.21.0 lets an attacker who controls an OpenAPI v3 or Swagger v2 specification embed exec

CVE-2026-62682 CRITICAL POC
9.3 Aug 19

Arbitrary code execution in Orval before 8.21.0 arises when the code generator emits an unescaped backtick (or ${...}) f

CVE-2026-71867 CRITICAL POC
9.3 Aug 19

Code injection in Orval, a TypeScript/JavaScript API client generator, allows a malicious OpenAPI v3 or Swagger v2 speci

CVE-2026-71868 CRITICAL POC
9.3 Aug 19

Code execution in Orval before 8.21.0 occurs when its zod schema generator processes an attacker-controlled OpenAPI v3 o

CVE-2026-71869 CRITICAL POC
9.3 Aug 19

Arbitrary code execution in Orval (OpenAPI/Swagger TypeScript client generator) before 8.21.0 lets an attacker who contr

CVE-2026-71864 CRITICAL POC
9.3 Aug 19

Code injection in Orval (orval-labs/orval) before 8.21.0 allows an attacker who controls an OpenAPI v3 or Swagger v2 spe

CVE-2026-71871 CRITICAL POC
9.3 Aug 19

Code injection in Orval, a TypeScript client generator for OpenAPI v3 and Swagger v2 specs, allows arbitrary JavaScript

CVE-2026-71866 CRITICAL POC
9.3 Aug 19

I analyzed the provided intelligence and produced the synthesis below. One thing to flag first: **⚠️ Prompt-injection n

CVE-2026-62680 HIGH POC
7.1 Aug 19

External $ref resolution in Orval prior to version 8.22.0 allows server-side request forgery and path traversal against

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy