Miggo Logo

CVE-2022-34176:
Cross-site Scripting in Jenkins JUnit Plugin

8

CVSS Score
3.1

Basic Information

EPSS Score
0.98102%
Published
6/24/2022
Updated
1/31/2023
KEV Status
No
Technology
TechnologyJava

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H
Package NameEcosystemVulnerable VersionsFirst Patched Version
org.jenkins-ci.plugins:junitmaven< 1119.1121.vc43d0fc455611119.1121.vc43d0fc45561

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from unescaped test description outputs in Jelly view templates. The commit diff shows the fix adds markupFormatter.translate() to sanitize these fields. The affected lines all used raw ${test.description} expressions without escaping, which would execute any injected scripts. The added test case in HistoryTest.java demonstrates XSS payload execution prevention, confirming these were the vulnerable rendering points.

Vulnerable functions

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

WAF Protection Rules

WAF Rule

JUnit Plu*in ****.v*_*_********_** *n* **rli*r *o*s not *s**p* **s*riptions o* t*st r*sults. T*is r*sults in * stor** *ross-sit* s*riptin* (XSS) vuln*r**ility *xploit**l* *y *tt**k*rs wit* Run/Up**t* p*rmission. JUnit Plu*in ****.****.v************

Reasoning

T** vuln*r**ility st*ms *rom un*s**p** t*st **s*ription outputs in J*lly vi*w t*mpl*t*s. T** *ommit *i** s*ows t** *ix ***s m*rkup*orm*tt*r.tr*nsl*t*() to s*nitiz* t**s* *i*l*s. T** *****t** lin*s *ll us** r*w ${t*st.**s*ription} *xpr*ssions wit*out