On this page (7 sections)
The Jane PHP libraries generate models and API clients from JSON Schema and OpenAPI specifications. A critical flaw, tracked as CVE-2026-63413, affects the open-api-3 generator (the Composer package jane-php/open-api-3) in every version before 7.12.0. A specially crafted header parameter name in an OpenAPI document can break out of a code comment in the generated client and place attacker-controlled PHP where it runs as soon as the client is instantiated.
If your project generates SDKs from OpenAPI files you did not write yourself, such as third-party vendor specs, or files from a repository others can edit, you should review this. Details below come from the GitHub advisory, which is the only source so far, so treat the picture as vendor-reported and still developing.
What happened
The Jane generator builds PHP code through the nikic/php-parser library. Strings placed into the code tree are escaped properly. Comment text is different: according to the advisory, PHPDoc comment content is emitted raw. The generated Client and Endpoint method docblocks include the OpenAPI header parameter name verbatim inside an array-shape annotation.
That means a header name containing the PHPDoc closing delimiter can end the comment early. Whatever follows is then parsed as real PHP in the body of the generated class. The advisory describes this leading to an added __construct method, which executes when the generated client is instantiated. Because applications instantiate clients on essentially every call, the injected code would run routinely once the SDK is in use.
The reporter states the issue was verified on version 7.11.2 with PHP 8.1. The advisory lists a publication date of Jul 9, 2026 in the janephp/janephp repository, followed by publication in the National Vulnerability Database on Nov 18, 2026 and in the GitHub Advisory Database on Nov 19, 2026. The fix is in release v7.12.0, with the change in pull request 960.
Technical details in plain terms
This is a classic injection problem. Generated source code is output built from untrusted input, and one output context (comments) was not neutralized while others (string literals) were. The comment terminator is just text to the PHP parser, so a value meant to be a label becomes code.
The CVSS v4 metrics in the advisory list network attack vector, low complexity, no privileges and no user interaction, with high impact on confidentiality, integrity and availability of the vulnerable system. The CVE description adds an important precondition: exploitation requires generating a client from an attacker-influenced OpenAPI document and then using the generated SDK. Code runs with the privileges of the consuming application.
Who is realistically exposed
- Projects that run Jane's open-api-3 generator against specs downloaded from vendors, partners, public registries or user uploads.
- CI pipelines that regenerate clients automatically from a spec stored in a repository where outside contributors can propose changes.
- Agencies and integrators that generate SDKs for many clients from documents supplied by those clients.
- Applications that already contain a client generated by a vulnerable version from an untrusted spec; the generated files themselves may carry the injected code.
If you only generate clients from specifications you author and review yourself, your exposure is much lower, but upgrading is still the right move. For broader habits that reduce this kind of risk, see our small business website security guide.
How to check your exposure
First, find out which version of the generator your project resolves. Run this in the project root to list the installed package and its version; anything below 7.12.0 is affected.
composer show jane-php/open-api-3To see whether the package is pulled in directly or through another dependency, ask Composer why it is installed. The output lists the packages that require it.
composer why jane-php/open-api-3Next, review generated code that came from specs you do not control. The following grep searches generated PHP for a docblock closing marker followed by a method declaration on the same line, which is unusual in generated output. Adjust the path to where your generated client lives; any hit deserves a manual look, and no hit is not proof of safety.
grep -rnE '\*/[[:space:]]*(public|private|protected)?[[:space:]]*function' path/to/generated-clientAlso inspect the OpenAPI documents themselves. Header parameter names should look like ordinary HTTP header names. Any name containing slashes, asterisks, braces or PHP keywords is a red flag.
What to do now
- Upgrade jane-php/open-api-3 to 7.12.0 or later, then commit the updated composer.lock.
- Regenerate every client that was produced by an earlier version, especially those built from third-party or user-supplied specs.
- Diff the regenerated output against what is deployed and review unexpected differences, such as extra methods in Client or Endpoint classes.
- If a vulnerable generator ran on an untrusted spec and the client was then executed, treat that environment as potentially compromised: rotate secrets available to that application and review recent activity.
- Stop auto-generating clients from unreviewed specs in CI; require review of spec changes first and run generation in an isolated, low-privilege job.
- Pin the generator version in composer.json and add dependency auditing to your pipeline.
To update only this package and its needed dependencies, run the following in your project root. It changes composer.lock, so run your tests afterward.
composer update jane-php/open-api-3 --with-dependenciesThe reporter's suggested fix was to neutralize the comment terminator in all generated PHPDoc text (parameter names and descriptions) and add a regression test. If you maintain a fork or your own template layer that writes comments from spec values, apply the same principle there.
Detection and monitoring
- Add a CI check that fails when generated files change unexpectedly after regeneration.
- Run composer audit regularly so advisories like this one surface automatically.
- Watch for unexpected outbound connections or new processes from application servers that load generated SDKs.
- Keep an eye on the Jane advisory for updates, since only one publisher covers this so far.
For the web-facing side of the same applications, a read-only scan and change monitoring can help you notice unexpected changes, though neither can see inside your build pipeline. Our guide on what outside-in detection can and cannot see explains those limits.
Timeline
| Date | Event |
|---|---|
| Jul 9, 2026 | Advisory published to the janephp/janephp repository |
| Nov 18, 2026 | Published by the National Vulnerability Database |
| Nov 19, 2026 | Published to and reviewed in the GitHub Advisory Database; last updated |
Sources
This article is based on the public sources below. Details can change as vendors and researchers publish more; check the original advisories before acting on version numbers.
