Miggo Logo

CVE-2024-23897: Arbitrary file read vulnerability through the Jenkins CLI can lead to RCE

9.8

CVSS Score
3.1

Basic Information

EPSS Score
0.99993%
Published
1/24/2024
Updated
12/20/2024
KEV Status
Yes
Technology
TechnologyJava

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Package NameEcosystemVulnerable VersionsFirst Patched Version
org.jenkins-ci.main:jenkins-coremaven>= 1.606, <= 2.426.22.426.3
org.jenkins-ci.main:jenkins-coremaven= 2.4412.442
org.jenkins-ci.main:jenkins-coremaven>= 2.427, < 2.440.12.440.1

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from args4j's expandAtFiles feature being enabled by default. The commit diff shows both CLICommand.java and CLIRegisterer.java were modified to add ParserProperties.withAtSyntax(false) via the ALLOW_AT_SYNTAX flag. The original vulnerable versions lacked these safeguards, creating parsers with default settings that permitted '@' file expansion. These two functions are the entry points for CLI argument parsing in both traditional and declarative command implementations.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

J*nkins **s * *uilt-in *omm*n* lin* int*r**** (*LI) to ****ss J*nkins *rom * s*ript or s**ll *nvironm*nt. J*nkins us*s t** *r*s*j li*r*ry to p*rs* *omm*n* *r*um*nts *n* options on t** J*nkins *ontroll*r w**n pro**ssin* *LI *omm*n*s. T*is *omm*n* p*r

Reasoning

T** vuln*r**ility st*ms *rom *r*s*j's *xp*n**t*il*s ***tur* **in* *n**l** *y ****ult. T** *ommit *i** s*ows *ot* *LI*omm*n*.j*v* *n* *LIR**ist*r*r.j*v* w*r* mo*i*i** to *** P*rs*rProp*rti*s.wit**tSynt*x(**ls*) vi* t** *LLOW_*T_SYNT*X *l**. T** ori*in