CVE-2021-4172: Cross-site Scripting in showdoc
5.4
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.40736%
CWE
Published
2/1/2022
Updated
2/3/2023
KEV Status
No
Technology
PHP
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
showdoc/showdoc | composer | < 2.10.2 | 2.10.2 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The key vulnerability is a stored XSS via SVG uploads. The commit diff shows a critical modification in web_src/src/models/page.js
where user-controlled values (one.value) were being concatenated into the page content without sanitization. While the vulnerability manifests via SVG uploads, the root cause is improper neutralization of input during content generation. The patch removed an unsafe interpolation of one.value, indicating this was part of the XSS vector. The function
's direct handling of user-supplied data aligns with the CWE-79 XSS classification.