CVE-2022-43405: Pipeline groovy lib Groovy Libraries Plugin And Pipeline: Vulnerability
HIGHCVE-2022-43405 is a HIGH (CVSS 8.8) groovy libraries plugin and pipeline: vulnerability (CWE-693: Protection Mechanism Failure) affecting Pipeline groovy lib libraries in the Maven ecosystem. The issue involves groovy libraries plugin and pipeline: deprecated groovy libraries plugin. Remediation is available by upgrading affected packages to version 613.v9c41a_160233f, 588.v576c103a_ff86.
CVE-2022-43405 at a Glance
Security Impact
CVSS: 8.8
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:H/I:H/A:H).
How to Fix CVE-2022-43405
To remediate this vulnerability, upgrade all affected Pipeline groovy lib dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
<dependency>
<groupId>io.jenkins.plugins</groupId>
<artifactId>pipeline-groovy-lib</artifactId>
<version>613.v9c41a_160233f</version>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-cps-global-lib</artifactId>
<version>588.v576c103a_ff86</version>
</dependency>
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
mvn dependency:tree -Dincludes=io.jenkins.plugins
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2022-43405, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=io.jenkins.plugins
Analyze the terminal output to locate any version of Pipeline groovy lib in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 613.v9c41a_160233f), your application is affected.
Note: The mvn dependency:tree -Dincludes=io.jenkins.plugins 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-693: Protection Mechanism Failure, where the product does not use or incorrectly uses a protection mechanism that provides sufficient defense against directed attacks against the product. In Pipeline groovy lib, 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
CVE-2022-43405 Affected Pipeline groovy lib Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
io.jenkins.plugins:pipeline-groovy-lib
|
Maven |
< 613.v9c41a_160233f
|
613.v9c41a_160233f
|
|
org.jenkins-ci.plugins.workflow:workflow-cps-global-lib
|
Maven |
< 588.v576c103a_ff86
|
588.v576c103a_ff86
|
References
Frequently Asked Questions
What is CVE-2022-43405?
Which Pipeline groovy lib versions are affected?
What version fixes CVE-2022-43405?
Is pipeline-groovy-lib affected?
Is workflow-cps-global-lib affected?
What is the CVSS score of CVE-2022-43405?
What CWE is associated with CVE-2022-43405?
How can I check Maven dependencies for CVE-2022-43405?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-4hjj-9gp7-4frg",
"modified" : "2022-12-16T16:35:55Z",
"published" : "2022-10-19T19:00:21Z",
"aliases" : [ "CVE-2022-43405" ],
"summary" : "Sandbox bypass vulnerability in Jenkins Pipeline: Groovy Libraries Plugin and Pipeline: Deprecated Groovy Libraries Plugin",
"details" : "Pipeline: Groovy Libraries Plugin and older releases of the Pipeline: Deprecated Groovy Libraries Plugin (formerly Pipeline: Shared Groovy Libraries Plugin) define the l`ibrary` Pipeline step, which allows Pipeline authors to dynamically load Pipeline libraries. The return value of this step can be used to instantiate classes defined in the loaded library.\n\nIn Pipeline: Groovy Libraries Plugin 612.v84da_9c54906d and earlier and in Pipeline: Deprecated Groovy Libraries Plugin 583.vf3b_454e43966 and earlier, the `library` step can be used to invoke sandbox-generated synthetic constructors in crafted untrusted libraries and construct any subclassable type. This is similar to SECURITY-582 in the [2017-08-07 security advisory](https://www.jenkins.io/security/advisory/2017-08-07/#multiple-groovy-language-features-allowed-script-security-plugin-sandbox-bypass), but in a different plugin.\n\nThis vulnerability allows attackers with permission to define untrusted Pipeline libraries and to define and run sandboxed Pipelines, to bypass the sandbox protection and execute arbitrary code in the context of the Jenkins controller JVM.\n\nPipeline: Groovy Libraries Plugin 613.v9c41a_160233f rejects improper calls to sandbox-generated synthetic constructors when using the `library` step.\n\nPipeline: Deprecated Groovy Libraries Plugin 588.v576c103a_ff86 no longer contains the `library` step. It has been moved into the Pipeline: Groovy Libraries Plugin.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "io.jenkins.plugins:pipeline-groovy-lib"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "613.v9c41a_160233f"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "< 613.v9c41a"
}
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.jenkins-ci.plugins.workflow:workflow-cps-global-lib"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "588.v576c103a_ff86"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 583.vf3b"
}
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-43405"
}, {
"type" : "WEB",
"url" : "https://www.jenkins.io/security/advisory/2022-10-19/#SECURITY-2824%20(2)"
}, {
"type" : "WEB",
"url" : "http://www.openwall.com/lists/oss-security/2022/10/19/3"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-693" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2022-10-19T22:04:27Z",
"nvd_published_at" : "2022-10-19T16:15:00Z"
}
}