Skip to main content

Orval EUVDEUVD-2026-62599

| CVE-2026-62681 CRITICAL
Code Injection (CWE-94)
2026-08-19 GitHub_M GHSA-fg9p-mrxr-hvq7
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
    Supply attacker-controlled OpenAPI/Swagger spec
  2. Delivery
    Embed backtick/`${` payload in path or server URL
  3. Exploit
    Orval emits it into client template literal
  4. Execution
    Developer or CI runs codegen and generated function
  5. Impact
    Arbitrary JavaScript executes in dev/CI/app 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 Orval (< 8.21.0) ingest an attacker-influenced OpenAPI v3 or Swagger v2 specification in which a path segment, servers[].url, or server-variable default contains an unescaped backtick, ${...} interpolation, or backslash; the victim must then generate an axios/fetch/react-query/SWR client and subsequently invoke the generated request, URL-builder, or query-key function (or run tests/build that do so) for the injected JavaScript to execute. Exploitation is limited by spec trust: environments that only generate clients from trusted internal specs are not realistically exposed, and no exploitation occurs unless codegen is actually run and the generated code executed. No authentication is involved because the attack surface is the spec content, not a running Orval service.

Impact

The vendor CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:N/UI:N, VC/VI/VA:H = 9.3 Critical) treats this as trivially exploitable code execution, and CWE-94 with confirmed vendor patch supports high severity. However, the real-world trigger is a supply-chain/spec-trust condition rather than a directly reachable network service: exploitation requires that Orval process an attacker-controlled OpenAPI/Swagger spec and that a developer or pipeline then run codegen and execute the generated function. That effectively involves victim action and dependence on untrusted input, so the true attack vector is closer to network-delivered-but-locally-triggered - I would score UI as required, which the vendor vector omits (verify against your threat model). No EPSS score, KEV entry, or SSVC decision was provided in the input, so probability of widespread exploitation cannot be quantified here; absence of KEV suggests no confirmed in-the-wild use. Net: a genuinely high-impact issue for anyone generating clients from third-party/untrusted specs, but lower practical risk for teams that only feed Orval trusted first-party specifications.

Exploit ScenarioDerived

An attacker publishes or supplies an OpenAPI spec whose path or server URL contains a payload such as http://api.x/+require('fs').writeFileSync('/marker','pwned')+`; a developer or CI job runs Orval against that spec, and the injected JavaScript becomes part of the generated request/URL-builder/query-key function. When that function is called (during tests, build, or app runtime), the attacker's code executes with the privileges of the developer or CI environment. The upstream fix tests include exactly such working payloads, so proof-of-concept is effectively public.

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 who controls an OpenAPI v3 or Swagger v2 specification embed executable JavaScript into generated client code. An unescaped backtick (and ${...} / backslash) in an OpenAPI path, server URL, or server-variable default is emitted verbatim into the template literals Orval generates for axios, fetch, react-query, and SWR clients, so attacker-controlled code runs whenever a generated request, URL-builder, or query-key function is invoked - inside the developer machine, CI pipeline, test suite, or running application. The upstream fix PR and security advisory include demonstrative injection payloads (e.g. require('child_process').execSync('id')), so working proof-of-concept exists, but there is no evidence of active exploitation (not in CISA KEV).

RemediationAI

Vendor-released patch: upgrade Orval to 8.21.0 or later (https://github.com/orval-labs/orval/releases/tag/v8.21.0; fix in PR https://github.com/orval-labs/orval/pull/3692, commit 8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6), which escapes spec-derived strings via jsStringLiteralEscape/jsesc before emitting them into template literals. Until you can upgrade, only run Orval against OpenAPI/Swagger specifications from fully trusted first-party sources and treat any externally supplied spec as untrusted code - review paths, servers[].url values, and server variable defaults for backticks, ${, or backslash sequences before generating; the trade-off is added manual review overhead. Additionally, run codegen and the generated test/build steps in a sandboxed or least-privilege CI runner so that any injected execution is contained, and regenerate/inspect all clients previously produced from third-party specs, since malicious code may already be baked into committed output.

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 code generator that converts OpenAPI/Swagger specs into type-safe TypeScript HTTP clients. The root cause is CWE-94 (Improper Control of Generation of Code, 'Code Injection'): the route generator in packages/core/src/getters/route.ts interpolated spec-derived strings (path segments, servers[].url, and server variable defaults) directly into backtick-delimited JavaScript template literals in the emitted client. Because backticks, ${ interpolation sequences, and backslashes were not escaped, a value in the input spec could close the template literal and append arbitrary JavaScript that becomes part of the generated source. The query-key getter (packages/core/src/getters/keys.ts) had the analogous single-quote/backslash flaw. The 8.21.0 fix introduces a jsStringLiteralEscape helper (backed by the jsesc library) applied in both getters so spec text is safely encoded as string-literal content rather than live code.

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 9.6 CRITICAL

Spec content is network-deliverable (AV:N) with no auth (PR:N), but a victim must run codegen and execute generated code (UI:R), and execution escapes Orval into the host/CI context (S:C) with full code execution (C/I/A:H).

3.1 AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
4.0 AV:N/AC:L/AT:P/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:31 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, an unescaped backtick in an OpenAPI path is emitted into request URL template literals generated for axios, fetch, react-query, and SWR clients without safe encoding. This permits attacker-controlled JavaScript to be evaluated when a generated request, URL-builder, or query-key function is called, resulting in code execution in the developer, CI, test, or application environment. The affected code is packages/core/src/getters/route.ts and route generation consumers. This issue is fixed in version 8.21.0.

Executive ViewAI

Why It Matters

Orval code generator versions before 8.21.0 contain a critical vulnerability that allows attackers who control OpenAPI specifications to inject arbitrary JavaScript into generated client code. Publicly available exploit code exists. This code executes on developer machines, in CI/CD pipelines, and within running applications, creating a supply-chain attack vector that could compromise both internal development processes and end-user applications.

Business Impact: Severe
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.5%
Top 58% exploitable
Prevalence
Medium
popular TypeScript OpenAPI client generator, developer-tooling footprint not universal
Threat Intel
1
1 source
Exploit
POC
Public exploit code exists
Data Quality
6 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA GitHub

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
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact
Very High
Technical Impact
Total

Priority Score

67
Low Medium High Critical
KEV: 0
EPSS: +1
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-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

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