CVE-2007-6382: Robocode.core Robocode Arbitrary Code Execution Vulnerability

MODERATE
Advisory Identifier: GHSA-xh22-fw58-56pp
CWE-94
Published
Advisory Summary

CVE-2007-6382 is a MODERATE robocode arbitrary code execution vulnerability (CWE-94: Improper Control of Generation of Code ('Code Injection')) affecting Robocode.core libraries in the Maven ecosystem. The issue involves robocode arbitrary code execution. Remediation is available by upgrading affected packages to version 1.5.1.

CVE-2007-6382 at a Glance

CVE Identifier CVE-2007-6382
GHSA Identifier GHSA-xh22-fw58-56pp
Severity MODERATE
CVSS v3.1 Base Score N/A
CWE Classification CWE-94: Improper Control of Generation of Code ('Code Injection')
Affected Product Robocode.core
Package Ecosystem Maven
Published Date
Last Updated

How to Fix CVE-2007-6382

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

net.sf.robocode:robocode.core fixed: 1.5.1
<dependency>
    <groupId>net.sf.robocode</groupId>
    <artifactId>robocode.core</artifactId>
    <version>1.5.1</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=net.sf.robocode

How to Check if You Are Affected

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

mvn dependency:tree -Dincludes=net.sf.robocode

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

Note: The mvn dependency:tree -Dincludes=net.sf.robocode 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 Robocode.core, 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

The Event Dispatch Thread in Robocode before 1.5.1 allows remote attackers to execute arbitrary Java code by using a robot to invoke the `SwingUtilities.invokeLater` method.

CVE-2007-6382 Affected Robocode.core Versions

1 component(s)
Fixed Versions:
1.5.1
Product / Package Ecosystem Affected Versions Fixed Version
net.sf.robocode:robocode.core
Maven
< 1.5.1
1.5.1

References

Frequently Asked Questions

What is CVE-2007-6382?
CVE-2007-6382 is a security vulnerability in Robocode.core involving Robocode Arbitrary Code Execution under CWE-94: Improper Control of Generation of Code ('Code Injection').
Which Robocode.core versions are affected?
Affected versions include releases prior to 1.5.1 across affected packages: net.sf.robocode:robocode.core.
What version fixes CVE-2007-6382?
Upgrading to 1.5.1 (or the latest patched release for your respective branch) resolves the vulnerability.
Is robocode.core affected?
Yes, net.sf.robocode:robocode.core is affected in releases prior to 1.5.1. Upgrade your dependency to 1.5.1 or later.
What CWE is associated with CVE-2007-6382?
CVE-2007-6382 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-2007-6382?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=net.sf.robocode'. 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-xh22-fw58-56pp",
  "modified" : "2023-09-21T23:22:16Z",
  "published" : "2022-05-01T18:42:25Z",
  "aliases" : [ "CVE-2007-6382" ],
  "summary" : "Robocode Arbitrary Code Execution",
  "details" : "The Event Dispatch Thread in Robocode before 1.5.1 allows remote attackers to execute arbitrary Java code by using a robot to invoke the `SwingUtilities.invokeLater` method.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "net.sf.robocode:robocode.core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.5.1"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2007-6382"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/robo-code/robocode/commit/2f2867d24fb28a2478983be57556f2355a774a81"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/robo-code/robocode/commit/8c6f5d77e7723583ba069ea611c33f22c1e9603a"
  }, {
    "type" : "WEB",
    "url" : "https://exchange.xforce.ibmcloud.com/vulnerabilities/39019"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/robo-code/robocode"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/robo-code/robocode/blob/1abe65b65c34a8eb3d23de8f037dafae3c548fa5/versions.md?plain=1#L1880-L1887"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-94" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2023-09-21T23:22:16Z",
    "nvd_published_at" : "2007-12-15T02:46:00Z"
  }
}