mobsf
Affected
- introduced
0, fixed4.2.9(ecosystem)
Fixed versions
4.2.9
Fix
- Fixed version
4.2.9pip install --upgrade mobsf==4.2.9
Advisory
Also known as: CVE-2024-53999, GHSA-5jc6-h9w7-jm3p
Mobile Security Framework (MobSF) Stored Cross-Site Scripting Vulnerability in "Diff or Compare" Functionality
Summary
The application allows users to upload files with scripts in the filename parameter. As a result, a malicious user can upload a script file to the system. When users in the application use the "Diff or Compare" functionality, they are affected by a Stored Cross-Site Scripting vulnerability.
Details
I found a Stored Cross-Site Scripting vulnerability in the "Diff or Compare" functionality. This issue occurs because the upload functionality allows users to upload files with special characters such as <, >, /, and " in the filename. This vulnerability can be mitigated by restricting file uploads to filenames containing only whitelisted characters, such as A-Z, 0-9, and specific special characters permitted by business requirements, like - or _ .
PoC
_Complete instructions, including specific configuration details, to reproduce the vulnerability._
test.zip.test.zip to <image src onerror=prompt(document.domain)>test.zip. This means I uploaded a file and set its name to a script value. As a result, the server allowed the file to be uploaded successfully.<image src onerror=prompt(document.domain)>test.zip in the recent scans. Then, I clicked on the "Differ or Compare" button."<image src onerror=prompt(document.domain)>test.zipImpact
Allowing a malicious user to upload a script in the filename parameter can be used to steal information from other users or administrators when they perform the compare functionality. The script will be stored in the system permanently in this vulnerability.
Medium Basis: CVSS v3 score 6.1, vector CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:U/C:H/I:H/A:N
0, fixed 4.2.9 (ecosystem)4.2.9
4.2.9pip install --upgrade mobsf==4.2.9Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: PyPA Advisory Database · CC BY 4.0