CVE-2021-37504: jQuery-Upload-File XSS in fileNameStr
6.1
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.70637%
CWE
Published
2/26/2022
Updated
4/2/2024
KEV Status
No
Technology
JavaScript
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
jquery-file-upload | npm | <= 4.0.11 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability occurs in filename handling where user-controlled input (file.name) is directly inserted into DOM via .html()
without sanitization. The serializeAndUploadFiles
function processes file names and passes them to progress dialogs using .html()
, while defaultProgressBar
's filename
element creation uses unsafe HTML injection. Both patterns violate XSS protection principles by failing to escape user-controlled content in HTML contexts.