CVE-2026-54621
Last modified
CVE-2026-54621 is a high-severity vulnerability rated 7.8/10 on the CVSS scale. datamodel-code-generator generates Python data models from schema definitions. Prior to 0.60.1, GraphQL Union description values in src/datamodel_code_generator/model/template/UnionTypeStatement.jinja2 and src/datamodel_code_generator/model/template/UnionTypeStatement.py312.jinja2 are rendered into Python comments without neutralizing carriage returns in Python # comments, allowing attacker-controlled GraphQL schema content to inject Python code into generated models that runs when imported. EPSS estimates a 0.14% chance of exploitation in the next 30 days.
Description
datamodel-code-generator generates Python data models from schema definitions. Prior to 0.60.1, GraphQL Union description values in src/datamodel_code_generator/model/template/UnionTypeStatement.jinja2 and src/datamodel_code_generator/model/template/UnionTypeStatement.py312.jinja2 are rendered into Python comments without neutralizing carriage returns in Python # comments, allowing attacker-controlled GraphQL schema content to inject Python code into generated models that runs when imported. This issue is fixed in version 0.60.1.
Metrics
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Weakness Enumeration
Affected Software
Source: CNA advisory (CVE.org). NVD analysis pending.
| Vendor | Product | Versions |
|---|---|---|
| koxudaxi | datamodel-code-generator | >= 0.25.0, < 0.60.1 |
References
Timeline
- Published
- Last Modified
- Status
- Deferred
Frequently Asked Questions
What is CVE-2026-54621?
How severe is CVE-2026-54621?
How do I fix CVE-2026-54621?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2026
- CVE-2026-54605OAuth is a Ruby wrapper for the OAuth 1.0 and 1.0a protocols…7.2
- CVE-2026-54607FastGPT is a knowledge-based AI application platform. Prior …7.7
- CVE-2026-54609QTI Neon is a minimal, game-agnostic, relay-based UDP multip…8.6
- CVE-2026-54619sqlite3 provides Ruby bindings for the SQLite3 embedded data…2
- CVE-2026-5462A vulnerability was identified in Wahoo Fitness SYSTM App up…3.3
- CVE-2026-54620sqlite3 provides Ruby bindings for the SQLite3 embedded data…2
- CVE-2026-5463Command injection vulnerability in console.run_module_with_o…9.8
- CVE-2026-54635pytonapi is a Python SDK for TONAPI that provides REST API, …7.5
- CVE-2026-54636Dokku is a docker-powered PaaS. Prior to 0.38.7, the cron pl…9.9
- CVE-2026-54638gotd/td is a T Telegram MTProto API client in Go. Prior to 0…7.5
- CVE-2026-54639Style Dictionary, a build system for creating cross-platform…8.8
- CVE-2026-5464The ExactMetrics – Google Analytics Dashboard for WordPress …7.2
Are you affected by CVE-2026-54621?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
