6.7medium
Unrestricted Upload of File with Dangerous Type in unisharp/laravel-filemanager
- Severity
- 6.7medium CVSS:3.1 by snyk
- Exploit likelihood
- 1.83% (higher than 79% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- snyk
- Also known as
- GHSA-f8x6-m9f5-ffp8SNYK-PHP-UNISHARPLARAVELFILEMANAGER-1567199
Description
This affects versions of the package unisharp/laravel-filemanager before 2.6.2. The upload() function does not sufficiently validate the file type when uploading. An attacker may be able to reproduce the following steps: 1. Install a package with a web Laravel application. 2. Navigate to the Upload window 3. Upload an image file, then capture the request 4. Edit the request contents with a malicious file (webshell) 5. Enter the path of file uploaded on URL - Remote Code Execution **Note:** Prevention for bad extensions can be done by using a whitelist in the config file(lfm.php). Corresponding document can be found in [here](https://unisharp.github.io/laravel-filemanager/configfolder-categories).
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| unisharp/laravel-filemanager | before 2.6.2 | CVE List |
| unisharp/laravel-filemanager (Packagist) | before 2.6.2 | GitHub Advisory Database |
| unisharp laravel-filemanager | from 0.0.0 | NVD |
All scores
| snyk | 6.7medium CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:L/E:P |
| GitHub | 6.7medium CVSS:3.1 | CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:L |
| NVD | 8.8high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| NVD | 6.5medium CVSS:2.0 | AV:N/AC:L/Au:S/C:P/I:P/A:P |
Classification
What each source says
CVE List
This affects versions of the package unisharp/laravel-filemanager before 2.6.2. The upload() function does not sufficiently validate the file type when uploading. An attacker may be able to reproduce the following steps: 1. Install a package with a web Laravel application. 2. Navigate to the Upload window 3. Upload an image file, then capture the request 4. Edit the request contents with a malicious file (webshell) 5. Enter the path of file uploaded on URL - Remote Code Execution **Note:** Prevention for bad extensions can be done by using a whitelist in the config file(lfm.php). Corresponding document can be found in [here](https://unisharp.github.io/laravel-filemanager/configfolder-categories).
GitHub Advisory Database
This affects the package unisharp/laravel-filemanager prior to version 2.6.2. The upload() function does not sufficiently validate the file type when uploading.
An attacker may be able to reproduce the following steps:
- Install a package with a web Laravel application.
- Navigate to the Upload window
- Upload an image file, then capture the request
- Edit the request contents with a malicious file (webshell)
- Enter the path of file uploaded on URL
- Remote Code Execution
**Note: Prevention for bad extensions can be done by using a whitelist in the config file(lfm.php). Corresponding document can be found in the here.
NVD (es)
Esto afecta al paquete unisharp/laravel-filemanager desde la versión 0.0.0. La función upload() no comprueba suficientemente el tipo de archivo cuando es cargado. Un atacante puede ser capaz de reproducir los siguientes pasos: - Instalar un paquete con una aplicación web Laravel. - Navegar a la ventana de subida - Subir un archivo de imagen, luego capturar la petición - Editar el contenido de la petición con un archivo malicioso (webshell) - Introducir la ruta del archivo subido en la URL - Ejecución de Código Remota. **Nota: La prevención para extensiones malas puede hacerse usando una lista blanca en el archivo de configuración (lfm.php). El documento correspondiente puede encontrarse en [aquí](https://unisharp.github.io/laravel-filemanager/configfolder-categories)
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2021-23814 changed 2025-06-17 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-f8x6-m9f5-ffp8 changed 2025-06-18 | CC-BY-4.0 |
| NVD | CVE-2021-23814 changed 2026-06-17 | Public domain |