Vulnerabilities in pkg:maven/org.apache.avro/avro-compiler

PACKAGE
Advisory Identifier: GHSA-rp46-r563-jrc7
Advisory Summary

CVE-2025-33042 is a MODERATE apache avro java sdk is vulnerability (CWE-94: Improper Control of Generation of Code ('Code Injection')) affecting Avro compiler libraries in the Maven ecosystem. The issue involves apache avro java sdk is vulnerable to code injection. Remediation is available by upgrading affected packages to version 1.12.1, 1.11.5.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:maven/org.apache.avro/avro-compiler

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:maven/org.apache.avro/avro-compiler. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-rp46-r563-jrc7 CVE-2025-33042 MODERATE Apache Avro Java SDK is Vulnerable to Code Injection

CVE-2025-33042 at a Glance

CVE Identifier CVE-2025-33042
GHSA Identifier GHSA-rp46-r563-jrc7
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-94: Improper Control of Generation of Code ('Code Injection')
Affected Product Avro compiler
Package Ecosystem Maven
Published Date
Last Updated

How to Fix CVE-2025-33042

To remediate this vulnerability, upgrade all affected Avro compiler dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

org.apache.avro:avro-compiler fixed: 1.12.1
<dependency>
    <groupId>org.apache.avro</groupId>
    <artifactId>avro-compiler</artifactId>
    <version>1.12.1</version>
</dependency>
org.apache.avro:avro-compiler fixed: 1.11.5
<dependency>
    <groupId>org.apache.avro</groupId>
    <artifactId>avro-compiler</artifactId>
    <version>1.11.5</version>
</dependency>
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

mvn dependency:tree -Dincludes=org.apache.avro

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2025-33042, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree -Dincludes=org.apache.avro

Analyze the terminal output to locate any version of Avro compiler in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.12.1), your application is affected.

Note: The mvn dependency:tree -Dincludes=org.apache.avro command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-94: Improper Control of Generation of Code ('Code Injection'), where the product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment. In Avro compiler, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Improper Control of Generation of Code ('Code Injection') vulnerability in Apache Avro Java SDK when generating specific records from untrusted Avro schemas. This issue affects Apache Avro Java SDK: all versions through 1.11.4 and version 1.12.0. Users are recommended to upgrade to version 1.12.1 or 1.11.5, which fix the issue.

CVE-2025-33042 Affected Avro compiler Versions

2 component(s)
Fixed Versions:
1.12.11.11.5
Product / Package Ecosystem Affected Versions Fixed Version
org.apache.avro:avro-compiler
Maven
≥ 1.12.0
< 1.12.1
All 1 versions
1.12.0
1.12.1
org.apache.avro:avro-compiler
Maven
< 1.11.5
1.11.5

References

Frequently Asked Questions

What is CVE-2025-33042?
CVE-2025-33042 is a security vulnerability in Avro compiler involving Apache Avro Java SDK is Vulnerable to Code Injection under CWE-94: Improper Control of Generation of Code ('Code Injection').
Which Avro compiler versions are affected?
Affected versions include releases prior to 1.12.1, 1.11.5 across affected packages: org.apache.avro:avro-compiler.
What version fixes CVE-2025-33042?
Upgrading to 1.12.1, 1.11.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is avro-compiler affected?
Yes, org.apache.avro:avro-compiler is affected in releases prior to 1.12.1, 1.11.5. Upgrade your dependency to 1.12.1, 1.11.5 or later.
What CWE is associated with CVE-2025-33042?
CVE-2025-33042 is classified under CWE-94: Improper Control of Generation of Code ('Code Injection') (The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.).
How can I check Maven dependencies for CVE-2025-33042?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.apache.avro'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rp46-r563-jrc7",
  "modified" : "2026-06-05T14:25:54Z",
  "published" : "2026-02-13T12:31:21Z",
  "aliases" : [ "CVE-2025-33042" ],
  "summary" : "Apache Avro Java SDK is Vulnerable to Code Injection",
  "details" : "Improper Control of Generation of Code ('Code Injection') vulnerability in Apache Avro Java SDK when generating specific records from untrusted Avro schemas.\n\nThis issue affects Apache Avro Java SDK: all versions through 1.11.4 and version 1.12.0.\n\nUsers are recommended to upgrade to version 1.12.1 or 1.11.5, which fix the issue.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.avro:avro-compiler"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.12.0"
      }, {
        "fixed" : "1.12.1"
      } ]
    } ],
    "versions" : [ "1.12.0" ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.avro:avro-compiler"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.11.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-33042"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/apache/avro/pull/3150"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/apache/avro/commit/84bc7322ca1c04ab4a8e4e708acf1e271541aac4"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/apache/avro"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/avro/PYSEC-2026-26.yaml"
  }, {
    "type" : "WEB",
    "url" : "https://issues.apache.org/jira/browse/AVRO-4053"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread/fy88wmgf1lj9479vrpt12cv8x73lroj1"
  }, {
    "type" : "WEB",
    "url" : "https://security.snyk.io/vuln/SNYK-JAVA-ORGAPACHEAVRO-15282783"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2026/02/12/2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-94" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-02-13T20:56:03Z",
    "nvd_published_at" : "2026-02-13T12:16:07Z"
  }
}