CVE-2020-13931: Apache tomee Remote Code Execution Vulnerability

CRITICAL
Advisory Identifier: GHSA-mp28-rq7g-qx62
CVSS 9.8
CWE-306
Published
Advisory Summary

CVE-2020-13931 is a CRITICAL (CVSS 9.8) remote code execution vulnerability (CWE-306: Missing Authentication for Critical Function) affecting Apache tomee libraries in the Maven ecosystem. The issue involves remote code execution in apache tomee. Remediation is available by upgrading affected packages to version 8.0.4, 7.1.4, 7.0.9.

CVE-2020-13931 at a Glance

CVE Identifier CVE-2020-13931
GHSA Identifier GHSA-mp28-rq7g-qx62
Severity CRITICAL
CVSS v3.1 Base Score 9.8
CWE Classification CWE-306: Missing Authentication for Critical Function
Affected Product Apache tomee
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 9.8

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:H/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 High (I:H)
Availability High (A:H)

How to Fix CVE-2020-13931

To remediate this vulnerability, upgrade all affected Apache tomee 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.tomee:apache-tomee fixed: 8.0.4
<dependency>
    <groupId>org.apache.tomee</groupId>
    <artifactId>apache-tomee</artifactId>
    <version>8.0.4</version>
</dependency>
org.apache.tomee:apache-tomee fixed: 7.1.4
<dependency>
    <groupId>org.apache.tomee</groupId>
    <artifactId>apache-tomee</artifactId>
    <version>7.1.4</version>
</dependency>
org.apache.tomee:apache-tomee fixed: 7.0.9
<dependency>
    <groupId>org.apache.tomee</groupId>
    <artifactId>apache-tomee</artifactId>
    <version>7.0.9</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.tomee

How to Check if You Are Affected

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

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

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

Note: The mvn dependency:tree -Dincludes=org.apache.tomee 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-306: Missing Authentication for Critical Function, where the product does not perform any authentication for functionality that requires a provable user identity or consumes a significant amount of resources. In Apache tomee, 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

If Apache TomEE 8.0.0-M1 - 8.0.3, 7.1.0 - 7.1.3, 7.0.0-M1 - 7.0.8, 1.0.0 - 1.7.5 is configured to use the embedded ActiveMQ broker, and the broker config is misconfigured, a JMX port is opened on TCP port 1099, which does not include authentication. CVE-2020-11969 previously addressed the creation of the JMX management interface, however the incomplete fix did not cover this edge case.

CVE-2020-13931 Affected Apache tomee Versions

3 component(s)
Fixed Versions:
8.0.47.1.47.0.9
Product / Package Ecosystem Affected Versions Fixed Version
org.apache.tomee:apache-tomee
Maven
≥ 8.0.0
< 8.0.4
8.0.4
org.apache.tomee:apache-tomee
Maven
≥ 7.1.0
< 7.1.4
7.1.4
org.apache.tomee:apache-tomee
Maven
< 7.0.9
7.0.9

References

Frequently Asked Questions

What is CVE-2020-13931?
CVE-2020-13931 is a security vulnerability in Apache tomee involving Remote code execution in Apache TomEE under CWE-306: Missing Authentication for Critical Function.
Which Apache tomee versions are affected?
Affected versions include releases prior to 8.0.4, 7.1.4, 7.0.9 across affected packages: org.apache.tomee:apache-tomee.
What version fixes CVE-2020-13931?
Upgrading to 8.0.4, 7.1.4, 7.0.9 (or the latest patched release for your respective branch) resolves the vulnerability.
Is apache-tomee affected?
Yes, org.apache.tomee:apache-tomee is affected in releases prior to 8.0.4, 7.1.4, 7.0.9. Upgrade your dependency to 8.0.4, 7.1.4, 7.0.9 or later.
What is the CVSS score of CVE-2020-13931?
CVE-2020-13931 has a CVSS v3.1 base score of 9.8 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
What CWE is associated with CVE-2020-13931?
CVE-2020-13931 is classified under CWE-306: Missing Authentication for Critical Function (The product does not perform any authentication for functionality that requires a provable user identity or consumes a significant amount of resources.).
How can I check Maven dependencies for CVE-2020-13931?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.apache.tomee'. 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-mp28-rq7g-qx62",
  "modified" : "2021-04-08T20:55:45Z",
  "published" : "2022-02-09T22:44:38Z",
  "aliases" : [ "CVE-2020-13931" ],
  "summary" : "Remote code execution in Apache TomEE",
  "details" : "If Apache TomEE 8.0.0-M1 - 8.0.3, 7.1.0 - 7.1.3, 7.0.0-M1 - 7.0.8, 1.0.0 - 1.7.5 is configured to use the embedded ActiveMQ broker, and the broker config is misconfigured, a JMX port is opened on TCP port 1099, which does not include authentication. CVE-2020-11969 previously addressed the creation of the JMX management interface, however the incomplete fix did not cover this edge case.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.tomee:apache-tomee"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "8.0.0"
      }, {
        "fixed" : "8.0.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.tomee:apache-tomee"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "7.1.0"
      }, {
        "fixed" : "7.1.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.apache.tomee:apache-tomee"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "7.0.9"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2020-13931"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r7f98907165b355dc65f28a57f15103a06173ce03261115fa46d569b4@%3Cdev.tomee.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/r85b87478f8aa4751aa3a06e88622e80ffabae376ee7283e147ee56b9@%3Cdev.tomee.apache.org%3E"
  }, {
    "type" : "WEB",
    "url" : "https://lists.apache.org/thread.html/ref088c4732e1a8dd0bbbb96e13ffafcfe65f984238ffa55f438d78fe%40%3Cdev.tomee.apache.org%3E"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-306" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-04-08T20:55:45Z",
    "nvd_published_at" : "2020-12-18T00:15:00Z"
  }
}