SCA: security update for datamodel-code-generator (GHSA-8m8r-38jm-f355)

high Tenable Cloud Security Plugin ID 445421

Description

There are packages installed that are affected by a vulnerability referenced in the following CVE:

- 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. From 0.52.1 until 0.60.2,
datamodel-code-generator interpolates validators from --extra-template-data in
src/datamodel_code_generator/model/pydantic_v2/base_model.py through _process_validators into
@field_validator decorators without safe validation, allowing Python code execution when the generated
Pydantic v2 model is imported. This issue is fixed in version 0.60.2. (CVE-2026-54656)

Solution

Update the datamodel-code-generator library and its related packages to version 0.60.2 or later.

See Also

https://github.com/advisories/GHSA-8m8r-38jm-f355

Plugin Details

Severity: High

ID: 445421

Version: Revision 1.2

Type: Local

Family: SCA Checks

Published: 7/29/2026

Updated: 7/29/2026

Risk Information

VPR

Risk Factor: Medium

Score: 4.9

Percentile: 58.15

Vendor

Vendor Severity: High

CVSS v2

Risk Factor: High

Base Score: 7.2

Temporal Score: 5.3

Vector: CVSS2#AV:L/AC:L/Au:N/C:C/I:C/A:C

CVSS Score Source: CVE-2026-54656

CVSS v3

Risk Factor: High

Base Score: 7.8

Temporal Score: 6.8

Vector: CVSS:3.0/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Temporal Vector: CVSS:3.0/E:U/RL:O/RC:C

Vulnerability Information

Exploit Ease: No known exploits are available

Patch Publication Date: 7/28/2026

Vulnerability Publication Date: 7/28/2026

Reference Information

CVE: CVE-2026-54656

cwe: CWE-94