Skip to main content

Orval CVE-2026-96758

| EUVDEUVD-2026-85408 CRITICAL
Code Injection (CWE-94)
2026-09-23 VulnCheck GHSA-f2xw-gqvf-336w
9.3
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

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

  1. Access
    Craft OpenAPI spec with ${...} in property name
  2. Delivery
    Deliver malicious spec to victim developer
  3. Exploit
    Victim runs orval codegen
  4. Execution
    Injected expression emitted into template literal
  5. Persist
    Generated client builds FormData, code executes
  6. Impact
    Arbitrary JS runs with consumer process privileges

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

Exploitation requires: (1) a victim using orval / @orval/core before 8.28.0 to generate an API client; (2) that victim feeding an attacker-controlled OpenAPI specification into the codegen; (3) the spec defining a multipart/form-data body whose property name embeds a ${...} template-literal expression; and (4) the victim building and running the generated client so it constructs a FormData body, at which point the injected expression executes with the consumer process's privileges. Limiting factors: this is a build-time/developer-tool flaw, not a runtime network service - it only affects organizations that generate clients from untrusted or externally sourced OpenAPI documents and then execute the output, which constitutes required user interaction the vendor's UI:N vector omits.

Impact

The vendor (via VulnCheck) rates this CVSS 4.0 9.3 with vector AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H, framing it as unauthenticated network RCE. That framing is misleading for a build-time code generator: the injected ${...} only executes when a developer runs orval codegen against an attacker-controlled OpenAPI spec and then integrates and executes the generated client that builds FormData bodies. That is a supply-chain / dev-tooling exposure gated on victim interaction, not a runtime network service exposed to anonymous attackers. So the true attack vector is 'attacker supplies malicious spec + victim developer generates and runs code' - I would score UI:R (CVSS 4.0 UI:P), lowering my estimate to roughly 8.8. No EPSS score, no CISA KEV listing, and no public exploit are present in the input, so exploitation status is 'no public exploit identified at time of analysis.' The code fix is concretely verifiable (PR #3988 adds backslash/backtick/${ escaping of multipart property keys), which confirms the root cause is unescaped keys interpolated into generated template literals. Net: a genuine code-injection bug worth patching in any CI/codegen pipeline that consumes third-party specs, but not a mass-exploitable internet-facing RCE - priority should track whether your org generates clients from untrusted OpenAPI documents.

Exploit ScenarioDerived

An attacker publishes or supplies a malicious OpenAPI specification whose multipart form-data property name contains a ${...} expression. A developer runs orval to generate a TypeScript API client from that spec; the unescaped key is emitted verbatim inside a template literal, and the injected expression executes as live JavaScript when the generated client constructs a FormData body, running with the consumer process's privileges. No public proof-of-concept is identified in the provided data, though the patch diff effectively documents the injection point.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
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 – Sep 23, 2026

Code injection in the Orval OpenAPI client generator (@orval/core before 8.28.0) lets an attacker who controls a multipart schema property name in a supplied OpenAPI document smuggle a ${...} template-literal expression into the generated client, which then executes as live JavaScript with the privileges of the process that builds or runs that client. The vendor rates this CVSS 4.0 9.3 (AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H), while our independent assessment scores it CVSS 3.1 8.8 (AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H) because exploitation is not reachable over a network service directly - it requires a developer to generate and then execute a client from an attacker-influenced spec, which is meaningful user interaction. This is a build-time/tooling supply-chain flaw: only organizations that feed untrusted, third-party, or externally sourced OpenAPI documents into Orval and then run the generated code are exposed. No public exploit code has been identified at time of analysis, and the issue is not listed in CISA KEV, though a vendor patch and the upstream fix commits are public, so weaponization of the technique is plausible for anyone who reads the advisory.

RemediationAI

The primary fix is to upgrade to @orval/core 8.28.0 or later (the first release containing PR #3988, commit 975a769a76151354dead879feadfa3537ff065fe), or to patch the dependency causing resolved Orval to 8.28.0 or above; verify the change with the GitHub security advisory at https://github.com/orval-labs/orval/security/advisories/GHSA-jwhm-6748-j6pq and audit generated clients for any surviving unescaped ` append(...) calls. If upgrade is not immediately possible, treat OpenAPI documents as executable code: only run codegen against specs from trusted first-party sources or specs that have been diff-reviewed, and never against a third-party or user-submitted spec (the trade-off is loss of automated onboarding of external APIs). Additionally, scan checked-in or generated client sources with a simple grep for ${ inside FormData .append( ` template literals to detect already-poisoned output, and regenerate rather than run any client that fails that check. For CI systems where codegen and execution happen in the same job, isolate the generator step in a container without cloud credentials, long-lived tokens, or filesystem write access outside the workspace, accepting the added pipeline complexity; note that simply disabling the multipart/form-data serializer is not supported as a configuration toggle, so upgrade or spec-sourcing controls are the practical options.

Affected VersionsENISA

orval 0 <8.28.0

Affected Packages

euvd orval fix: 8.28.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

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

Technical ContextAI · show details

The root cause is CWE-94 (improper control of generation of code), specifically a code-generation escaping failure in the form-data serializer. In packages/core/src/getters/res-req-types.ts (around line 808 in v8.27.0), the function resolveSchemaPropertiesToFormData builds the source text of the generated client by interpolating OpenAPI schema property names directly into template literals such as ` ${variableName}.append(\${keyPrefix}${key}\, ...) . Because the property name is never escaped for the surrounding backtick context, an attacker-authored key like ${process.env.SECRET} or ${require('child_process').execSync('...')} is emitted verbatim into the generated .ts file and evaluated as a real interpolation when the client constructs a FormData body. The upstream fix in PR #3988 / commit 975a769a76151354dead879feadfa3537ff065fe introduces an escapedKey variable that applies .replace(/\\/g,'\\\\'), .replace(//g,'\\`') and .replace(/\$\{/g,'\\${') before every append()/keyPrefix interpolation site, neutralizing backslash, backtick, and template-expression metacharacters. The affected component is the npm package @orval/core (CPE cpe:2.3:a:orval-labs:orval:*:*:*:*:*:*:*:*), a TypeScript code generator that turns OpenAPI 3.x specifications into typed HTTP clients; the vulnerable code path is reached only when a spec declares a multipart/form-data request body, since only then does the serializer emit property-name literals into the generated FormData assembly.

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 (VulnCheck) 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

Attacker needs no privileges (PR:N) but the victim must run codegen on the malicious spec and execute the generated client (UI:R); resulting code execution yields full C/I/A on the consumer process.

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 (VulnCheck).

CVSS VectorVendor: VulnCheck

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

DescriptionCVE.org

orval @orval/core before 8.28.0 contains a code injection vulnerability in the form-data serializer that fails to escape multipart property names in generated template literals. Attackers can inject ${...} expressions into OpenAPI schema property names that execute as live interpolation when the generated client builds FormData bodies with consumer process privileges.

Technical POC Analysis

CWE-94: Improper Control of Generation of Code.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

A critical code-injection flaw in Orval's OpenAPI client generator (@orval/core versions before 8.28.0) allows an attacker who controls a schema property name in a third-party API specification to inject executable JavaScript into the client that our teams generate and run. Organizations are only exposed if they feed externally sourced or untrusted OpenAPI documents into Orval and then execute the resulting code, meaning the risk concentrates in engineering and CI/CD build environments rather than customer-facing systems; a compromise there could expose pipeline credentials, source code, and downstream software artifacts. Because no public exploit code has been identified at time of analysis, this is a manageable but high-priority supply-chain exposure requiring prompt upgrade and process controls.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.5%
Top 57% exploitable
Prevalence
Low
popular open-source TS OpenAPI codegen, but dev-time-only footprint
Social Media
1
Sightings
Data Quality
4 sources
Confidence: Medium

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 No
EPSS 0.5%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity
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
Scheduled
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Total

Priority Score

47
Low Medium High Critical
KEV: 0
EPSS: +1
CVSS: +46
PoC: 0
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-71865 CRITICAL POC
9.3 Aug 19

Code injection in Orval before 8.21.0 lets an attacker-controlled OpenAPI v3 / Swagger v2 specification achieve arbitrar

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

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