CVE-2025-2905: Am distribution parent WSO2 API Manager XML External Vulnerability

CRITICAL
Advisory Identifier: GHSA-h94w-8qhg-3xmc
CVSS 9.1
CWE-611
Published
Advisory Summary

CVE-2025-2905 is a CRITICAL (CVSS 9.1) wso2 api manager xml external vulnerability (CWE-611: Improper Restriction of XML External Entity Reference) affecting Am distribution parent libraries in the Maven ecosystem. The issue involves wso2 api manager xml external entity (xxe) vulnerability. Remediation is available by upgrading affected packages to version 2.1.0.

CVE-2025-2905 at a Glance

CVE Identifier CVE-2025-2905
GHSA Identifier GHSA-h94w-8qhg-3xmc
Severity CRITICAL
CVSS v3.1 Base Score 9.1
CWE Classification CWE-611: Improper Restriction of XML External Entity Reference
Affected Product Am distribution parent
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 9.1

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2025-2905

To remediate this vulnerability, upgrade all affected Am distribution parent 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.wso2.am:am-distribution-parent fixed: 2.1.0
<dependency>
    <groupId>org.wso2.am</groupId>
    <artifactId>am-distribution-parent</artifactId>
    <version>2.1.0</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.wso2.am

How to Check if You Are Affected

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

mvn dependency:tree -Dincludes=org.wso2.am

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

Note: The mvn dependency:tree -Dincludes=org.wso2.am 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-611: Improper Restriction of XML External Entity Reference, where the product processes an xml document that can contain xml entities with uris that resolve to documents outside of the intended sphere of control, causing the product to embed incorrect documents into its output. In Am distribution parent, 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

An XML External Entity (XXE) vulnerability exists in the gateway component of WSO2 API Manager due to insufficient validation of XML input in crafted URL paths. User-supplied XML is parsed without appropriate restrictions, enabling external entity resolution. This vulnerability can be exploited by an unauthenticated remote attacker to read files from the server’s filesystem or perform denial-of-service (DoS) attacks. * On systems running JDK 7 or early JDK 8, full file contents may be exposed. * On later versions of JDK 8 and newer, only the first line of a file may be read, due to improvements in XML parser behavior. * DoS attacks such as "Billion Laughs" payloads can cause service disruption.

CVE-2025-2905 Affected Am distribution parent Versions

1 component(s)
Fixed Versions:
2.1.0
Product / Package Ecosystem Affected Versions Fixed Version
org.wso2.am:am-distribution-parent
Maven
< 2.1.0
2.1.0

References

Frequently Asked Questions

What is CVE-2025-2905?
CVE-2025-2905 is a security vulnerability in Am distribution parent involving WSO2 API Manager XML External Entity (XXE) vulnerability under CWE-611: Improper Restriction of XML External Entity Reference.
Which Am distribution parent versions are affected?
Affected versions include releases prior to 2.1.0 across affected packages: org.wso2.am:am-distribution-parent.
What version fixes CVE-2025-2905?
Upgrading to 2.1.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is am-distribution-parent affected?
Yes, org.wso2.am:am-distribution-parent is affected in releases prior to 2.1.0. Upgrade your dependency to 2.1.0 or later.
What is the CVSS score of CVE-2025-2905?
CVE-2025-2905 has a CVSS v3.1 base score of 9.1 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H.
What CWE is associated with CVE-2025-2905?
CVE-2025-2905 is classified under CWE-611: Improper Restriction of XML External Entity Reference (The product processes an XML document that can contain XML entities with URIs that resolve to documents outside of the intended sphere of control, causing the product to embed incorrect documents into its output.).
How can I check Maven dependencies for CVE-2025-2905?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.wso2.am'. 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-h94w-8qhg-3xmc",
  "modified" : "2025-05-05T19:58:08Z",
  "published" : "2025-05-05T09:31:09Z",
  "aliases" : [ "CVE-2025-2905" ],
  "summary" : "WSO2 API Manager XML External Entity (XXE) vulnerability",
  "details" : "An XML External Entity (XXE) vulnerability exists in the gateway component of WSO2 API Manager due to insufficient validation of XML input in crafted URL paths. User-supplied XML is parsed without appropriate restrictions, enabling external entity resolution.\n\nThis vulnerability can be exploited by an unauthenticated remote attacker to read files from the server’s filesystem or perform denial-of-service (DoS) attacks.\n\n  *  On systems running JDK 7 or early JDK 8, full file contents may be exposed.\n\n  *  On later versions of JDK 8 and newer, only the first line of a file may be read, due to improvements in XML parser behavior.\n\n  *  DoS attacks such as \"Billion Laughs\" payloads can cause service disruption.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.wso2.am:am-distribution-parent"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.1.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-2905"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/wso2/product-apim"
  }, {
    "type" : "WEB",
    "url" : "https://security.docs.wso2.com/en/latest/security-announcements/security-advisories/2025/WSO2-2025-3993"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-611" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-05-05T19:58:08Z",
    "nvd_published_at" : "2025-05-05T09:15:15Z"
  }
}