CVE-2022-32065: RuoYi 4.7.3 vulnerable to arbitrary file upload in background management module
5.4
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.61307%
CWE
Published
7/14/2022
Updated
1/27/2023
KEV Status
No
Technology
Java
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 |
---|---|---|---|
com.ruoyi:ruoyi | maven | < 4.7.4 | 4.7.4 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from insufficient file type validation in the avatar upload functionality. The updateAvatar controller method directly processes user-supplied files without initially enforcing image extensions. The patch adds MimeTypeUtils.IMAGE_EXTENSION validation to FileUploadUtils.upload calls, indicating the original implementation lacked proper filtering. The POC demonstrates exploiting this by uploading HTML files through the avatar endpoint, which would be handled by these functions. The commit diff confirms these were the exact locations modified to address the vulnerability.