CVE-2024-47804: Jenkins core Jenkins Item Creation Restriction Bypass Vulnerability

MODERATE
Advisory Identifier: GHSA-f9qj-77q2-h5c5
CVSS 4.3
CWE-843 CWE-863
Published
Advisory Summary

CVE-2024-47804 is a MODERATE (CVSS 4.3) jenkins item creation restriction bypass vulnerability (CWE-843: Access of Resource Using Incompatible Type ('Type Confusion')) affecting Jenkins core libraries in the Maven ecosystem. The issue involves jenkins item creation restriction bypass vulnerability. Remediation is available by upgrading affected packages to version 2.462.3, 2.479.

CVE-2024-47804 at a Glance

CVE Identifier CVE-2024-47804
GHSA Identifier GHSA-f9qj-77q2-h5c5
Severity MODERATE
CVSS v3.1 Base Score 4.3
CWE Classification CWE-843: Access of Resource Using Incompatible Type ('Type Confusion')
Affected Product Jenkins core
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 4.3

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

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

How to Fix CVE-2024-47804

To remediate this vulnerability, upgrade all affected Jenkins 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.

org.jenkins-ci.main:jenkins-core fixed: 2.462.3
<dependency>
    <groupId>org.jenkins-ci.main</groupId>
    <artifactId>jenkins-core</artifactId>
    <version>2.462.3</version>
</dependency>
org.jenkins-ci.main:jenkins-core fixed: 2.479
<dependency>
    <groupId>org.jenkins-ci.main</groupId>
    <artifactId>jenkins-core</artifactId>
    <version>2.479</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.jenkins-ci.main

How to Check if You Are Affected

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

mvn dependency:tree -Dincludes=org.jenkins-ci.main

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

Note: The mvn dependency:tree -Dincludes=org.jenkins-ci.main 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-843: Access of Resource Using Incompatible Type ('Type Confusion'), where the product allocates or initializes a resource such as a pointer, object, or variable using one type, but it later accesses that resource using a type that is incompatible with the original type. In Jenkins 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

Jenkins provides APIs for fine-grained control of item creation: - Authorization strategies can prohibit the creation of items of a given type in a given item group (`ACL#hasCreatePermission2`). - Item types can prohibit creation of new instances in a given item group (`TopLevelItemDescriptor#isApplicableIn(ItemGroup)`). If an attempt is made to create an item of a prohibited type through the Jenkins CLI or the REST API and either of the above checks fail, Jenkins 2.478 and earlier, LTS 2.462.2 and earlier creates the item in memory, only deleting it from disk. This allows attackers with Item/Create permission to bypass these restrictions, creating a temporary item. With Item/Configure permission, they can also save the item to persist it. If an attempt is made to create an item of a prohibited type through the Jenkins CLI or the REST API and either of the above checks fail, Jenkins 2.479, LTS 2.462.3 does not retain the item in memory.

CVE-2024-47804 Affected Jenkins core Versions

2 component(s)
Fixed Versions:
2.462.32.479
Product / Package Ecosystem Affected Versions Fixed Version
org.jenkins-ci.main:jenkins-core
Maven
< 2.462.3
2.462.3
org.jenkins-ci.main:jenkins-core
Maven
≥ 2.466
< 2.479
2.479

References

Frequently Asked Questions

What is CVE-2024-47804?
CVE-2024-47804 is a security vulnerability in Jenkins core involving Jenkins item creation restriction bypass vulnerability under CWE-843: Access of Resource Using Incompatible Type ('Type Confusion').
Which Jenkins core versions are affected?
Affected versions include releases prior to 2.462.3, 2.479 across affected packages: org.jenkins-ci.main:jenkins-core.
What version fixes CVE-2024-47804?
Upgrading to 2.462.3, 2.479 (or the latest patched release for your respective branch) resolves the vulnerability.
Is jenkins-core affected?
Yes, org.jenkins-ci.main:jenkins-core is affected in releases prior to 2.462.3, 2.479. Upgrade your dependency to 2.462.3, 2.479 or later.
What is the CVSS score of CVE-2024-47804?
CVE-2024-47804 has a CVSS v3.1 base score of 4.3 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N.
What CWE is associated with CVE-2024-47804?
CVE-2024-47804 is classified under CWE-843: Access of Resource Using Incompatible Type ('Type Confusion') (The product allocates or initializes a resource such as a pointer, object, or variable using one type, but it later accesses that resource using a type that is incompatible with the original type.).
How can I check Maven dependencies for CVE-2024-47804?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.jenkins-ci.main'. 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-f9qj-77q2-h5c5",
  "modified" : "2024-10-02T21:50:43Z",
  "published" : "2024-10-02T18:31:32Z",
  "aliases" : [ "CVE-2024-47804" ],
  "summary" : "Jenkins item creation restriction bypass vulnerability",
  "details" : "Jenkins provides APIs for fine-grained control of item creation:\n\n- Authorization strategies can prohibit the creation of items of a given type in a given item group (`ACL#hasCreatePermission2`).\n\n- Item types can prohibit creation of new instances in a given item group (`TopLevelItemDescriptor#isApplicableIn(ItemGroup)`).\n\nIf an attempt is made to create an item of a prohibited type through the Jenkins CLI or the REST API and either of the above checks fail, Jenkins 2.478 and earlier, LTS 2.462.2 and earlier creates the item in memory, only deleting it from disk.\n\nThis allows attackers with Item/Create permission to bypass these restrictions, creating a temporary item. With Item/Configure permission, they can also save the item to persist it.\n\nIf an attempt is made to create an item of a prohibited type through the Jenkins CLI or the REST API and either of the above checks fail, Jenkins 2.479, LTS 2.462.3 does not retain the item in memory.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.jenkins-ci.main:jenkins-core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.462.3"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.jenkins-ci.main:jenkins-core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.466"
      }, {
        "fixed" : "2.479"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-47804"
  }, {
    "type" : "WEB",
    "url" : "https://www.jenkins.io/security/advisory/2024-10-02/#SECURITY-3448"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-843", "CWE-863" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-10-02T21:50:43Z",
    "nvd_published_at" : "2024-10-02T16:15:10Z"
  }
}