{"id":"GHSA-3575-w9fc-c2j6","revision":null,"records":[{"revision":"c24208724f7f44c19ddbe40a3fca7cab","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-71868","aliases":[],"title":"Orval: Import-time RCE via enum-typed default -> zod module-level template literal","description":"Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a ${...} expression or backtick in an enum default is emitted into a module-level template literal emitted by zod schema generation 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 function formatDefaultValue. This issue is fixed in version 8.21.0.","state":0,"publishedAt":"2026-08-19T17:37:34.092+00:00","modifiedAt":"2026-08-21T19:43:39.471+00:00","affected":[{"ecosystem":"Vendor product","name":"orval","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"orval-labs\",\n                    \"product\": \"orval\",\n                    \"versions\": [\n                        {\n                            \"version\": \"< 8.21.0\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 4.0","vector":"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","score":9.3,"severity":"CRITICAL"}],"references":["https://github.com/orval-labs/orval/security/advisories/GHSA-3575-w9fc-c2j6","https://github.com/orval-labs/orval/pull/3692","https://github.com/orval-labs/orval/commit/8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6","https://github.com/orval-labs/orval/releases/tag/v8.21.0"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-71868","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-71868","identifiers":["CVE-2026-71868"]},"retained":false,"historicalAffected":[]},{"revision":"429a5f9d206a45438f21ce8913854027","observedAt":"2026-11-11T16:02:56.182+00:00","statement":{"source":"euvd","id":"EUVD-2026-62605","aliases":["CVE-2026-71868","GHSA-3575-w9fc-c2j6"],"title":"Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a ${...} expression or backtick in an enum default is emitted into a module-level template literal emitted by zod sch…","description":"Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a ${...} expression or backtick in an enum default is emitted into a module-level template literal emitted by zod schema generation 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 function formatDefaultValue. This issue is fixed in version 8.21.0.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 4.0","vector":"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","score":9.3,"severity":null}],"references":["https://github.com/orval-labs/orval/security/advisories/GHSA-3575-w9fc-c2j6","https://github.com/orval-labs/orval/pull/3692","https://github.com/orval-labs/orval/commit/8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6","https://github.com/orval-labs/orval/releases/tag/v8.21.0"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2026-62605","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"Aug 19, 2026, 5:37:34 PM","dateUpdated":"Aug 21, 2026, 7:43:39 PM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2026-62605","identifiers":["EUVD-2026-62605","CVE-2026-71868","GHSA-3575-w9fc-c2j6"]},"retained":false,"historicalAffected":[]},{"revision":"fdb8176c5b424bc68f8698f98eed2035","observedAt":"2026-10-25T15:19:03.401+00:00","statement":{"source":"nvd","id":"CVE-2026-71868","aliases":[],"title":"Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a ${...} expression or backtick in an enum default is emitted into a module-level template literal emitted by zod sch…","description":"Orval generates type-safe JavaScript clients in TypeScript from OpenAPI v3 and Swagger v2 specifications. Prior to 8.21.0, a ${...} expression or backtick in an enum default is emitted into a module-level template literal emitted by zod schema generation 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 function formatDefaultValue. This issue is fixed in version 8.21.0.","state":0,"publishedAt":"2026-08-19T18:17:24.413+00:00","modifiedAt":"2026-09-09T21:20:38.86+00:00","affected":[],"metrics":[{"system":"CVSS 4.0 · security-advisories@github.com · Secondary","vector":"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/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","score":9.3,"severity":"CRITICAL"}],"references":["https://github.com/orval-labs/orval/commit/8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6","https://github.com/orval-labs/orval/pull/3692","https://github.com/orval-labs/orval/releases/tag/v8.21.0","https://github.com/orval-labs/orval/security/advisories/GHSA-3575-w9fc-c2j6"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-71868","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Deferred","weaknesses":["CWE-94","CWE-1336"],"productCriteria":[],"sourceDates":{"published":"2026-08-19T18:17:24.413","lastModified":"2026-09-09T21:20:38.860"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-71868","identifiers":["CVE-2026-71868"]},"retained":false,"historicalAffected":[]},{"revision":"e75a16b4b213488199124490970630e9","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-3575-w9fc-c2j6","aliases":["CVE-2026-71868"],"title":"Orval: Import-time RCE via enum-typed default -> zod module-level template literal","description":"### Summary\n\nOrval's zod schema generation emits the **enum-typed** `default` value as a module-level template literal (`export const …Default = `<default>`;`) without escaping `${` or the backtick. A default of the form `v${<code>}w` injects a live JavaScript expression evaluated when the generated zod schema module is imported, executing attacker-controlled code at import — no request or function call needed. Verified on Orval 8.19.0; survives default OpenAPI validation.\n\n### Details\n\n```ts\nexport const …Default = `v${globalThis.ORVPWN()}w`;   // ${...} = arbitrary JS expression, runs at import\n```\n\nMalicious input: an enum-typed property with a `default` of `v${<attacker JS>}w`. `${...}` permits any JS expression.\n\nNote: this is one of several `default`-bearing positions that reach the same unescaped zod template-literal sink; a single fix (escape `default` values) closes all of them, and a CNA may choose to consolidate the related reports.\n\n### PoC\n\n`reproduce.sh` (+ `make_spec.py`) attached: generates the zod schema with default validation, bundles it, imports it, and shows a marker written at import. Verified on 8.19.0.\n\n### Impact\n\nCode execution at import in any application that imports a zod schema module generated from an attacker-controlled or attacker-influenced OpenAPI description.\n\n### Suggested fix\n\nEmit `default` values via a proper string-literal encoder (JSON.stringify, or escape backtick and `${` if a template literal must be used); never interpolate a spec value into a template literal. Apply to every `default` position.","state":0,"publishedAt":"2026-09-03T18:20:55+00:00","modifiedAt":"2026-09-18T05:30:05.8327862+00:00","affected":[{"ecosystem":"npm","name":"orval","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"8.21.0"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V4","vector":"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","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"CRITICAL"}],"references":["https://github.com/orval-labs/orval/security/advisories/GHSA-3575-w9fc-c2j6","https://nvd.nist.gov/vuln/detail/CVE-2026-71868","https://github.com/orval-labs/orval/pull/3692","https://github.com/orval-labs/orval/commit/8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6","https://github.com/orval-labs/orval","https://github.com/orval-labs/orval/releases/tag/v8.21.0"],"sourceUrl":"https://github.com/advisories/GHSA-3575-w9fc-c2j6","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-3575-w9fc-c2j6","identifiers":["GHSA-3575-w9fc-c2j6","CVE-2026-71868"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-13T05:18:48.7948660+00:00","complete":true,"records":1779,"lastAttemptAt":"2026-11-13T05:18:48.794866+00:00","lastSuccessAt":"2026-11-13T05:18:48.9994933+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:18:48.9995061+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-d8fa82e95fdb59244e2f635e667ba17f0796ca0a4f1f4bb8cc31febcd660b76c-1c5172d098efb637fed8eab7555210eb25d4abf20f74026a02377bb1124cd3de","complete":true,"records":424960,"lastAttemptAt":"2026-11-13T05:16:37.7971751+00:00","lastSuccessAt":"2026-11-13T05:16:37.7566327+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:16:37.7971751+00:00","snapshotPublishedAt":"2026-11-13T04:23:58+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-81649827bed04d178218ae3481877efc","complete":false,"records":13793,"lastAttemptAt":"2026-11-13T05:28:42.5594492+00:00","lastSuccessAt":"2026-11-13T05:28:42.555+00:00","error":"563 identifier lookups failed; latest failures include AccessDenied (HTTP 403). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-13T05:28:42.555+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13226,"expectedIdentifiers":13846,"failedIdentifiers":563},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-13T05:18:48.7948660+00:00","complete":true,"records":1123,"lastAttemptAt":"2026-11-13T05:18:48.794866+00:00","lastSuccessAt":"2026-11-13T05:18:49.0004529+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:18:49.0004538+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-77eeb9ad53d240dc91f8e3d507ac52a2","complete":false,"records":13781,"lastAttemptAt":"2026-11-13T05:18:54.2339757+00:00","lastSuccessAt":"2026-11-13T04:18:42.877+00:00","error":"12 identifier lookups failed; latest failures include HttpError (HTTP 503). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-13T04:18:42.877+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13834,"expectedIdentifiers":13846,"failedIdentifiers":12},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-93e76d404e1aeb6a7e8902f5ffa06211fc86dea3b1958e297abb2668aa5e6e8c","complete":true,"records":9952,"lastAttemptAt":"2026-11-13T05:18:48.714791+00:00","lastSuccessAt":"2026-11-12T23:19:15.5239119+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:18:48.714791+00:00","snapshotPublishedAt":"2026-11-12T23:03:02+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-4d60731753a2f72e455d1086e7203d0ef10843936dcc1cf2b45135e2caa204b0","complete":true,"records":2012,"lastAttemptAt":"2026-11-13T05:16:37.937734+00:00","lastSuccessAt":"2026-11-12T18:16:50.7862525+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:16:37.937734+00:00","snapshotPublishedAt":"2026-11-12T17:48:11+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-20d1a8ab073a1c13ab2143dbcadb34ebb8edf1e18e16482b448513662c3d1e12","complete":true,"records":3127,"lastAttemptAt":"2026-11-13T05:18:48.7320885+00:00","lastSuccessAt":"2026-11-12T22:18:31.0338213+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:18:48.7320885+00:00","snapshotPublishedAt":"2026-11-12T22:18:06+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-9c400afecc368c19e27d85b853d7f36c26a1688896f9e96b3e569d052492b938","complete":true,"records":231765,"lastAttemptAt":"2026-11-13T05:18:48.5554824+00:00","lastSuccessAt":"2026-11-13T05:18:46.7416005+00:00","error":null,"lastVerifiedAt":"2026-11-13T05:18:48.5554824+00:00","snapshotPublishedAt":"2026-11-13T04:48:05+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}