{"id":"CVE-2026-33686","published":"2026-03-26T21:54:25Z","modified":"2026-03-27T13:59:50Z","title":"Sharp is Vulnerable to Path Traversal via Unsanitized Extension in FileUtil","vendor":"code16","product":"sharp","tier":"tail","description":{"text":"Sharp is a content management framework built for Laravel as a package. Versions prior to 9.20.0 have a path traversal vulnerability  in the FileUtil class. The application fails to sanitize file extensions properly, allowing path separators to be passed into the storage layer. In `src/Utils/FileUtil.php`, the `FileUtil::explodeExtension()` function extracts a file's extension by splitting the filename at the last dot. This issue has been patched in version 9.20.0 by properly sanitizing the extension using `pathinfo(PATHINFO_EXTENSION)` instead of `strrpos()`, alongside applying strict regex replacements to both the base name and the extension.","provenance":"source","from":"CVE.org"},"cvss":{"score":8.8,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00604,"percentile":0.4982,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"references":[{"url":"https://github.com/code16/sharp/security/advisories/GHSA-9ffq-6457-8958","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/code16/sharp/pull/715","tags":["x_refsource_MISC"]}],"priority":{"score":16.1,"factors":[{"name":"EPSS percentile","points":9.96},{"name":"CVSS severity","points":6.16}]},"vendorSlug":"code16","affectedVersions":[{"vendor":"code16","product":"sharp","versions":["< 9.20.0"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total","timestamp":"2026-03-27T13:59:38.470602Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Packagist","package":"code16/sharp","vulnerableRanges":["<9.20.0"],"patched":["9.20.0"],"from":["GHSA-9ffq-6457-8958"],"provenance":"source"}],"summary":{"text":"The Sharp content management framework for Laravel, in its FileUtil class (src/Utils/FileUtil.php), fails to sanitize file extensions, so path traversal sequences can reach the storage layer through the explodeExtension() function, which splits filenames at the last dot. An attacker with network access and low-privilege authentication can exploit this without any user interaction to read or modify files outside the intended storage directory, with the attack relying on the default configuration of the affected component.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:26:13Z"},"euvd":{"id":"EUVD-2026-16446","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2025-61457","published":"2025-10-21","fixed":"9.7.0","kev":false},{"cve":"CVE-2025-62798","published":"2025-10-28","fixed":"9.11.1","kev":false,"link":{"from":"CVE-2025-62798","to":"CVE-2026-33686","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:code16/sharp","fromFixed":"9.11.1","toFixed":"9.20.0","daysApart":149}]}},{"cve":"CVE-2026-33686","published":"2026-03-26","fixed":"9.20.0","kev":false},{"cve":"CVE-2026-33687","published":"2026-03-26","fixed":"9.20.0","kev":false},{"cve":"CVE-2026-44692","published":"2026-06-10","fixed":"9.22.0","kev":false},{"cve":"CVE-2026-53634","published":"2026-06-10","fixed":"9.22.3","kev":false}],"package":"Packagist:code16/sharp"}}