CVE-2026-105801: openapi-python-client Malicious OpenAPI Documents Can Cause Vulnerability

HIGH
Advisory Identifier: GHSA-5293-mq8x-g3xj
CWE-116 CWE-94 CWE-150
Published
Advisory Summary

CVE-2026-105801 is a HIGH malicious openapi documents can cause vulnerability (CWE-116: Improper Encoding or Escaping of Output) affecting openapi-python-client libraries in the PyPI ecosystem. The issue involves malicious openapi documents can cause arbitrary code generation. Remediation is available by upgrading affected packages to version 0.29.1.

CVE-2026-105801 at a Glance

CVE Identifier CVE-2026-105801
GHSA Identifier GHSA-5293-mq8x-g3xj
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-116: Improper Encoding or Escaping of Output
Affected Product openapi-python-client
Package Ecosystem PyPI
Published Date
Last Updated

How to Fix CVE-2026-105801

To remediate this vulnerability, upgrade all affected openapi-python-client dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

openapi-python-client fixed: 0.29.1
pip install openapi-python-client>=0.29.1
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show openapi-python-client

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2026-105801, inspect your installed packages using pip:

pip show openapi-python-client

Analyze the terminal output to locate any version of openapi-python-client in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.29.1), your application is affected.

Note: The pip show openapi-python-client command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-116: Improper Encoding or Escaping of Output, where the product prepares a structured message for communication with another component, but encoding or escaping of the data is either missing or done incorrectly. as a result, the intended structure of the message is not preserved. In openapi-python-client, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact A malicious OpenAPI document processed by any `openapi-python-client` prior to 0.29.1 can generate arbitrary Python code. When anyone imports the malicious client, that arbitrary Python code will execute. ### Patches Versions starting with 0.29.1 have updated with guardrails to prevent arbitrary code generation. Upgrade to this version immediately and audit any code previously generated from untrusted documents. ### Workarounds Do not generate clients for documents you don't completely trust. Carefully verify any existing generated code from untrusted documents.

CVE-2026-105801 Affected openapi-python-client Versions

1 component(s)
Fixed Versions:
0.29.1
Product / Package Ecosystem Affected Versions Fixed Version
openapi-python-client
PyPI
< 0.29.1
0.29.1

References

Frequently Asked Questions

What is CVE-2026-105801?
CVE-2026-105801 is a security vulnerability in openapi-python-client involving Malicious OpenAPI Documents can cause Arbitrary Code Generation under CWE-116: Improper Encoding or Escaping of Output.
Which openapi-python-client versions are affected?
Affected versions include releases prior to 0.29.1 across affected packages: openapi-python-client.
What version fixes CVE-2026-105801?
Upgrading to 0.29.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is openapi-python-client affected?
Yes, openapi-python-client is affected in releases prior to 0.29.1. Upgrade your dependency to 0.29.1 or later.
What CWE is associated with CVE-2026-105801?
CVE-2026-105801 is classified under CWE-116: Improper Encoding or Escaping of Output (The product prepares a structured message for communication with another component, but encoding or escaping of the data is either missing or done incorrectly. As a result, the intended structure of the message is not preserved.).
How can I check PyPI dependencies for CVE-2026-105801?
Run the dependency tree command: 'pip show openapi-python-client'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-5293-mq8x-g3xj",
  "modified" : "2026-10-06T15:32:53Z",
  "published" : "2026-10-06T15:32:53Z",
  "aliases" : [ "CVE-2026-105801" ],
  "summary" : "openapi-python-client: Malicious OpenAPI Documents can cause Arbitrary Code Generation",
  "details" : "### Impact\nA malicious OpenAPI document processed by any `openapi-python-client` prior to 0.29.1 can generate arbitrary Python code. When anyone imports the malicious client, that arbitrary Python code will execute.\n\n### Patches\nVersions starting with 0.29.1 have updated with guardrails to prevent arbitrary code generation. Upgrade to this version immediately and audit any code previously generated from untrusted documents.\n\n### Workarounds\nDo not generate clients for documents you don't completely trust. Carefully verify any existing generated code from untrusted documents.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:H/VA:N/SC:H/SI:H/SA:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "openapi-python-client"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.29.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/openapi-generators/openapi-python-client/security/advisories/GHSA-5293-mq8x-g3xj"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-105801"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/openapi-generators/openapi-python-client/pull/1483"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/openapi-generators/openapi-python-client/commit/1c99af478892e5bbe6583b92acba431c9dec9186"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/openapi-generators/openapi-python-client"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/openapi-generators/openapi-python-client/releases/tag/v0.29.1"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-116", "CWE-150", "CWE-94" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-10-06T15:32:53Z",
    "nvd_published_at" : "2026-10-06T15:17:17Z"
  }
}