Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessCraft OpenAPI spec with ${...} in schema default
-
DeliveryDeliver spec to victim's codegen pipeline
-
ExploitVictim runs @orval/effect generator
-
ExecutionPayload emitted into generated module source
-
PersistBuild/import executes injected JS at module scope
-
ImpactArbitrary code execution 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 | Exploitation requires that a victim run orval's @orval/effect generator against an OpenAPI document that an attacker can influence, and that the attacker-controlled schema |
| Impact | The vendor-supplied CVSS 4.0 base score is 9.3 (AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H), and the flaw is a genuine CWE-94 code injection with full CIA impact and a confirmed fix, but real-world urgency is materially lower than that headline number because this is a build-time/developer-tooling vulnerability, not a runtime-service exposure. Exploitation requires an attacker to control the OpenAPI document that a victim then feeds through orval's @orval/effect generator - so despite AV:N, there is no directly reachable network listener; the 'network' vector reflects that the malicious spec can be delivered remotely (e.g. a shared/third-party API schema). The vendor's UI:N is questionable: a developer must actively run codegen (and build/import the output) for the injected JavaScript to execute, which is closer to UI:R/UI:A - my adjusted 3.1 estimate is ~8.8. No EPSS score, no CISA KEV listing, and no weaponized public exploit are present in the provided data (the PR contains regression tests that demonstrate the mechanism but not a packaged exploit), so this reads as a high-impact-but-conditional supply-chain issue rather than evidence of active mass exploitation. Priority is high for teams that run orval against untrusted or externally-authored OpenAPI specs in CI/build pipelines, and low for teams that only generate from their own trusted specs. |
| Exploit ScenarioDerived | An attacker publishes or supplies a malicious OpenAPI document whose schema |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 23, 2026
Code injection in the Orval OpenAPI client generator's @orval/effect package (versions 8.14.0 through 8.28.1) lets an attacker who can influence an OpenAPI schema embed arbitrary JavaScript expressions in the generated validation module, which execute at module scope as soon as that generated code is built or imported. The injection point is the schema default value, which the effect generator rewrites into a template literal so that ${...} syntax (or a literal backtick) re-arms interpolation, with numeric constraints such as minimum/maximum/multipleOf similarly emitted as unquoted expressions; exploitation is remote and does not require prior credentials per the vendor vector (PR:N), but it does require the victim to run the generator against an untrusted or third-party spec and then build or import the output, giving injected code the developer's build-time privileges. No public exploit code has been identified at time of analysis and the issue is patched upstream, so real-world urgency is lower than the vendor's CVSS 4.0 score of 9.3 suggests - this is a build-time/developer-tooling flaw rather than a network-facing service exposure (independent assessment: CVSS 3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H, reflecting the victim interaction the vendor rating understates).
RemediationAI
Primary fix: upgrade Orval past 8.28.1 to a release that includes upstream PR #3995 / commit d346d94a660e50a2f8d0f7c17fee2c4c69d8dc23 (vendor patch availability confirmed); consult the advisory at https://github.com/orval-labs/orval/security/advisories/GHSA-q7f2-jg6j-r867 for the vendor-recommended version, and note that a released patched version number is not independently confirmed here - verify against the tag before relying on it. If you cannot upgrade immediately, treat every OpenAPI document that is not produced and reviewed by your own team as untrusted input: do not run the @orval/effect generator against third-party, partner, or externally sourced specs, and scrub or reject schema default values containing ${ or backticks and any minimum/maximum/exclusiveMinimum/exclusiveMaximum/multipleOf value that is not a finite number before codegen. Because the payload only fires when the generated module is built or imported, diff-review generated output for unexpected expressions prior to committing or importing it, and pin the Orval dependency to a known-good version so transitive installs cannot silently reintroduce a vulnerable release. Run codegen in an isolated, low-privilege environment - a throwaway container with no production secrets, restricted network egress, and read-only mounts - so a successful injection cannot pivot into CI credentials; the trade-off is added pipeline complexity and slower builds. Teams that cannot drop the effect generator can switch temporarily to a different Orval target generator, accepting the migration cost of regenerating clients, while recognizing that the same patch also hardened Hono path and zod escaping and that the safest course is the version upgrade itself.
Affected VersionsENISA
Affected Packages
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
Root cause is CWE-94 (improper control of generation of code / code injection) in a code generator, a class that is easy to miss in SAST because the vulnerable sink is a string being emitted into source rather than an interpreter call. Orval converts an OpenAPI document into client/validation code; the @orval/effect generator (packages/effect/src/index.ts, roughly lines 298-302 in v8.28.1) built the default value for a schema by stringifying it and then swapping the single-quote delimiters for backticks. That substitution does not re-escape the content for the new template-literal context, so a default containing ${...} becomes live interpolation and a default containing a backtick can break out of the literal entirely. The same generator emitted numeric/length constraints (minimum, maximum, exclusiveMinimum, exclusiveMaximum, multipleOf) as bare unquoted expressions inside statements such as export const <name>Min<n> = <value>;, so a non-numeric attacker-supplied value was written verbatim into generated source. Because injected expressions are evaluated at module scope when the generated file is compiled or imported, an attacker controlling the spec effectively achieves code execution in the developer's or CI build environment. The upstream fix (PR #3995 / commit d346d94a, plus a companion safety fix for boolean-form exclusiveMinimum/exclusiveMaximum in OpenAPI 3.0) adds an assertSafeNumericConstraint helper that rejects any constraint that is not a finite number, stops re-delimiting stringified defaults into template literals, normalizes boolean exclusive flags to undefined instead of false, and additionally hardens string-literal escaping in the Hono route path generator and the zod generator. CPE data identifies the affected package line as cpe:2.3:a:orval-labs:orval:*:*:*:*:*:*:*:* (the orval-labs/orval repository/publication).
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
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
Malicious spec can be delivered remotely (AV:N) but the victim must actively run codegen and build/import output (UI:R); no auth needed (PR:N), and injected JS runs with full CIA in the same dev/build context (S:U, C/I/A:H).
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
orval versions 8.14.0 through 8.28.1 contain a code injection vulnerability in the @orval/effect generator that converts OpenAPI schema defaults into template literals. Attackers can inject arbitrary JavaScript expressions via schema defaults containing ${...} syntax, which are executed at module scope when the generated code is built or imported.
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
The Orval OpenAPI client generator's @orval/effect package (versions 8.14.0 through 8.28.1) contains a critical code-injection flaw that allows a malicious or compromised OpenAPI schema to execute arbitrary JavaScript in the generated validation module when it is built or imported. This puts engineering teams, CI/CD pipelines, and build-time credentials at risk because injected code runs with the developer's or build system's privileges. No public exploit identified at time of analysis, but the issue is unauthenticated per the vendor vector (PR:N) and requires only that the generator process an untrusted or third-party spec.
Apply vendor patch.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
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.
orval (TypeScript API client generator) before 7.18.0 has code injection via OpenAPI specification summary fields in MCP
Arbitrary code execution in Orval (orval-labs/orval) before 8.21.0 allows an attacker who controls an OpenAPI v3 or Swag
Code injection in Orval before 8.21.0 lets an attacker-controlled OpenAPI v3 or Swagger v2 specification execute arbitra
Code injection in Orval before 8.21.0 lets an attacker who controls an OpenAPI v3 or Swagger v2 specification embed exec
Arbitrary code execution in Orval before 8.21.0 arises when the code generator emits an unescaped backtick (or ${...}) f
Code injection in Orval, a TypeScript/JavaScript API client generator, allows a malicious OpenAPI v3 or Swagger v2 speci
Code execution in Orval before 8.21.0 occurs when its zod schema generator processes an attacker-controlled OpenAPI v3 o
Code injection in Orval before 8.21.0 lets an attacker-controlled OpenAPI v3 / Swagger v2 specification achieve arbitrar
Arbitrary code execution in Orval (OpenAPI/Swagger TypeScript client generator) before 8.21.0 lets an attacker who contr
Code injection in Orval (orval-labs/orval) before 8.21.0 allows an attacker who controls an OpenAPI v3 or Swagger v2 spe
Code injection in Orval, a TypeScript client generator for OpenAPI v3 and Swagger v2 specs, allows arbitrary JavaScript
I analyzed the provided intelligence and produced the synthesis below. One thing to flag first: **⚠️ Prompt-injection n
EUVD-2026-85405
GHSA-qr45-pvfw-p22r
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB