{"id":"CVE-2021-23814","published":"2021-12-17T20:00:14Z","modified":"2025-06-17T11:38:06Z","title":"This affects versions of the package unisharp/laravel-filemanager before 2.6.2","vendor":null,"product":null,"tier":"tail","description":{"text":"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.\r\rAn attacker may be able to reproduce the following steps:\r\r1. Install a package with a web Laravel application.\r2. Navigate to the Upload window\r3. Upload an image file, then capture the request\r4. Edit the request contents with a malicious file (webshell)\r5. Enter the path of file uploaded on URL - Remote Code Execution\r\r\r**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).","provenance":"source","from":"CVE.org"},"cvss":{"score":6.7,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:L/E:P","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.0183,"percentile":0.7939,"provenance":"source"},"cwes":[{"id":"CWE-94","name":"Improper Control of Generation of Code"}],"references":[{"url":"https://security.snyk.io/vuln/SNYK-PHP-UNISHARPLARAVELFILEMANAGER-1567199","tags":[]},{"url":"https://github.com/UniSharp/laravel-filemanager/blob/master/src/Controllers/UploadController.php%23L26","tags":[]},{"url":"https://github.com/UniSharp/laravel-filemanager/releases/tag/v2.5.1","tags":[]},{"url":"https://github.com/UniSharp/laravel-filemanager/issues/1113","tags":[]},{"url":"https://github.com/UniSharp/laravel-filemanager/releases/tag/v2.6.2","tags":[]},{"url":"https://snyk.io/vuln/SNYK-PHP-UNISHARPLARAVELFILEMANAGER-1567199","tags":["x_transferred"]},{"url":"https://github.com/UniSharp/laravel-filemanager/issues/1113#issuecomment-1812092975","tags":["x_transferred"]}],"priority":{"score":20.6,"factors":[{"name":"EPSS percentile","points":15.88},{"name":"CVSS severity","points":4.69}]},"affectedVersions":[{"vendor":"n/a","product":"unisharp/laravel-filemanager","versions":["< 2.6.2"]}],"affected":[{"ecosystem":"Packagist","package":"unisharp/laravel-filemanager","vulnerableRanges":["<2.6.2"],"patched":["2.6.2"],"from":["GHSA-f8x6-m9f5-ffp8"],"provenance":"source"}],"euvd":{"id":"EUVD-2022-0578","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-unisharp-laravel-filemanager-cve-2021-23814","children":[{"from":"CVE-2021-23814","to":"CVE-2024-21546","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["src/LfmUploadValidator.php"],"commits":["https://github.com/UniSharp/laravel-filemanager/commit/bd84899ce65a7f193e676dd8444e424fa50f64fa","https://github.com/UniSharp/laravel-filemanager/commit/8170760c0ae316d77b9363cd4c76ab68d3f63f0b"],"basis":"rarely changed file"},{"kind":"similar","provenance":"machine","score":0.44,"basis":"same package + description similarity"}]}],"packageHistory":[{"cve":"CVE-2021-23814","published":"2021-12-17","fixed":"2.6.2","kev":false},{"cve":"CVE-2022-40734","published":"2022-09-14","fixed":"2.6.4","kev":false,"link":{"from":"CVE-2021-23814","to":"CVE-2022-40734","relation":"successor","confidence":"medium","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:unisharp/laravel-filemanager","fromFixed":"2.6.2","toFixed":"2.6.4","daysApart":271},{"kind":"similar","provenance":"machine","score":0.39,"basis":"same package + description similarity"}]}},{"cve":"CVE-2024-21546","published":"2024-12-18","fixed":"2.9.1","kev":false}],"package":"Packagist:unisharp/laravel-filemanager"}}