Impact
The vulnerability lies in the code generation logic of the openapi-python-client. When processing an OpenAPI document, the generator does not neutralize malicious content before embedding it into Python source code, including string literals, docstrings, and f-strings. An attacker can embed arbitrary Python code in the specification; once the client library is imported, that code runs within the importing process, compromising the integrity of the environment and potentially leaking data or interrupting operations.
Affected Systems
Affected users are those employing the openapi-generators openapi-python-client tool to generate client libraries. Any generation that preceded version 0.29.1 is vulnerable; the fix was introduced in release v0.29.1. No specific older sub‑versions are listed, so all prior releases are considered affected.
Risk and Exploitability
With a CVSS score of 8.4 this vulnerability is considered high severity. No EPSS score is available and the issue is not cataloged in the CISA KEV list, so publicly known exploitation activity is not confirmed. The attack requires an attacker to supply a crafted OpenAPI document and a victim to generate (or import) the resulting client library; the code is executed in the context of the importing process. Thus, the most likely attack vector is local code execution via a trusted generation workflow or import process that processes untrusted specifications.
OpenCVE Enrichment
Github GHSA