CVE-2026-108375: dataclasses-avroschema code injection in generated Python modules

CVE-2026-108375 · Severity: high · CVSS 8.8 · Published 2026-10-13

dataclasses-avroschema is a Python library that generates Avro schemas and Python code from dataclass definitions. An attacker who controls the schema can inject malicious code into the generated Python modules, which executes automatically when those modules are imported. This allows arbitrary code execution in applications that process untrusted schemas.

Technologies: Dataclasses-Avroschema. Vendors: Dataclasses-Avroschema.

Quick answers

Is CVE-2026-108375 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-108375 being exploited in the wild.
How severe is CVE-2026-108375?
High severity, with a CVSS score of 8.8, published 13 October 2026.
Which products and versions are affected?
Dataclasses-Avroschema 0.38.0 through 0.70.5.
Is there a fix for CVE-2026-108375?
Yes: fixed in 0.70.6. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-108375 attacked?
It is attacked over the network, in a software library.
Am I affected by CVE-2026-108375?
Check whether you run Dataclasses-Avroschema at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • Fixed in: 0.70.6

Technical details

The FieldRepresentation.get_field_default method in versions 0.38.0 through 0.70.5 fails to escape schema-controlled string, UUID, bytes, and fixed field defaults when rendering them into quoted string literals in generated Python source code. An attacker can craft a malicious default value that terminates the string literal and injects arbitrary Python statements, which execute during module import. Version 0.70.6 resolves this by properly escaping schema values.

Affected products

  • dataclasses-avroschema dataclasses-avroschema 0.38.0 through 0.70.5

Timeline

  • 2026-10-13: disclosed
  • 2026-08-18: patched: Version 0.70.6 released

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.