Skip to main content

CVE-2026-105801: CWE-94: Improper Control of Generation of Code ('Code Injection') in openapi-generators openapi-python-client

0
High
Published: 10/06/2026 (10/06/2026, 14:53:42 UTC)
Source: CVE Database V5
Vendor/Project: openapi-generators
Product: openapi-python-client

Description

### 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.

CVSS v4.0

Score 8.4high

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vuln. Confidentiality
None
Vuln. Integrity
High
Vuln. Availability
None
Subsq. Confidentiality
High
Subsq. Integrity
High
Subsq. Availability
High
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 software

openapi-generators

openapi-python-client

Affected versions
<0.29.1
openapi-python-client
pkg:pypi/openapi-python-client
Affected versions
<0.29.1

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 10/06/2026, 15:18:22 UTC

Technical Analysis

openapi-python-client versions before 0.29.1 improperly control the generation of code by failing to safely neutralize malicious OpenAPI document content before rendering it into string, docstring, and f-string contexts in generated Python clients. This leads to code injection (CWE-94), where attacker-controlled Python code can be embedded and executed upon importing the generated client. This vulnerability affects the importing environment's integrity, confidentiality, and availability. The vulnerability is addressed in version 0.29.1.

Potential Impact

An attacker who can supply a malicious OpenAPI document can cause the generation of a Python client containing arbitrary Python code. This code executes when the client is imported, potentially compromising the importing environment's integrity, confidentiality, and availability. This could lead to unauthorized code execution and system compromise in environments that use the affected versions of openapi-python-client.

Mitigation Recommendations

Upgrade openapi-python-client to version 0.29.1 or later, where this code injection vulnerability is fixed. Avoid using generated clients from untrusted OpenAPI documents until the upgrade is applied.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
GitHub_M
Date Reserved
2026-10-05T20:37:19.364Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6ac50de12cdf04f656bca329

Added to database: 10/06/2026, 15:04:01 UTC

Last enriched: 10/06/2026, 15:18:22 UTC

Last updated: 10/06/2026, 18:57:28 UTC

Views: 12

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses