CVE-2026-22785 orval MCP client is vulnerable to a code injection attack.
- Exploited in the wild
- Not known
- Fix
- Available
What is CVE-2026-22785?
CVE-2026-22785 is a critical vulnerability in orval-labs orval, published on 12 Jan 2026.
Official description
orval generates type-safe JS clients (TypeScript) from any valid OpenAPI v3 or Swagger v2 specification. Prior to 7.18.0, the MCP server generation logic relies on string manipulation that incorporates the summary field from the OpenAPI specification without proper validation or escaping. This allows an attacker to "break out" of the string literal and inject arbitrary code. This vulnerability is fixed in 7.18.0.
Weakness: CWE-77
Which versions are affected by CVE-2026-22785?
2 open source packages ship an affected version, including @orval/mcp. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
@orval/mcp npm | All versions | 7.18.0 |
@orval/mcp npm | All versions | 7.18.0 |
Products include Orval Orval.
How do I fix CVE-2026-22785?
Upgrade @orval/mcp to 7.18.0 or later.
Is CVE-2026-22785 being exploited?
There is no known exploitation of CVE-2026-22785 in the wild and no public exploit code.
Public exploit code: 1 proofs of concept on GitHub.
Other vulnerabilities in orval-labs orval
Sources
Also known as GHSA-mwr6-3gp8-9jmj.