CVE-2026-55389: datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI
48
This week
HIGH 7.5REMOTEUPGRADE
CVE-2026-55389 is a high-severity flaw (CVSS 7.5) affecting datamodel-code-generator. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.
datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI, JSON Schema, GraphQL, Avro, Protobuf, and raw JSON, YAML, or CSV. Prior to 0.62.0, datamodel-code-generator resolves JSON Schema $ref targets in src/datamodel_code_generator/parser/jsonschema.py through is_url and _get_ref_body without containing file:// or ../ traversal references to the input directory and without honoring --no-allow-
Why this priority
- High severity
- Public exploit reference
- Remotely exploitable, no login, no user action
A fixed release or distro patch exists.
Publisher (CNA): GitHub, Inc. · Vendor: koxudaxi
Am I affected?
Timeline
- Published CVE record published
- Updated Record last modified
koxudaxi datamodel-code-generator UPGRADE
Affected: < 0.62.0
Fixed in: 0.62.0
Safe to downgrade to: no unaffected older release
1. Check installed version
apt-cache policy datamodel-code-generator || rpm -q datamodel-code-generator || datamodel-code-generator --version
2. UPGRADE to 0.62.0 (Debian / Ubuntu)
sudo apt update && sudo apt install --only-upgrade datamodel-code-generator
2. UPGRADE (RHEL / Amazon Linux / Fedora)
sudo dnf upgrade datamodel-code-generator
Note
Distros often backport fixes without changing the version number. Confirm with the distro advisory or changelog.
Exact fixes by distribution
Python (pip) · datamodel-code-generator · FIXED · 0.62.0 · vulnerable: <= 0.61.0 · source
pip install --upgrade "datamodel-code-generator>=0.62.0"
pip show datamodel-code-generator
Fedora 46 · python-fontconfig · FIXED · 0.6.3-1.fc46 · FEDORA-2026-f92ca8b01f · source
sudo dnf upgrade --advisory=FEDORA-2026-f92ca8b01f
Fedora ELN · valgrind · FIXED · 3.28.0-1.eln159 · FEDORA-2026-c593ef1d15 · source
sudo dnf upgrade --advisory=FEDORA-2026-c593ef1d15
Verify at the official source NVD · CVE Program · Report a problem with this page
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Related CVEs
- CVE-2026-54653 HIGH 8.8 UPGRADE datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI
- CVE-2026-54690 HIGH 8.2 UPGRADE datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI
- CVE-2026-55391 HIGH 7.5 UPGRADE datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI
- CVE-2026-55415 HIGH 7.5 UPGRADE datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI
- CVE-2026-54656 HIGH 7.8 UPGRADE datamodel-code-generator generates Pydantic v2 models, dataclasses, TypedDict, and msgspec.Struct from OpenAPI