CVE-2026-126779 is a high-severity (CVSS 7.5) CWE-73 vulnerability in spatie browsershot. A fix is available — see the affected versions and patch details below.
Spatie Browsershot 2.2.0 before 5.5.0 contains a local file read vulnerability that allows attackers to read server files by supplying root-relative references in HTML passed to setHtml().…
Description
Spatie Browsershot 2.2.0 before 5.5.0 contains a local file read vulnerability that allows attackers to read server files by supplying root-relative references in HTML passed to setHtml(). Attackers can embed iframe, img, link or script elements referencing paths like /etc/passwd, which resolve to file:// URLs and render file contents into the returned PDF or screenshot.
Affected Products
browsershotspatieDetection & mitigation playbook
Vendor / applianceDetect
Inventory every spatie browsershot deployment and check each version against the affected-products list above.
Fix
Apply the spatie browsershot security patch or hotfix for CVE-2026-126779 on the affected version, following the vendor advisory for your exact build.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands. Alongside that, restrict the management interface to trusted networks and apply the vendor's recommended configuration mitigations.
Frequently Asked Questions
Is CVE-2026-126779 being exploited in your environment?
Detect and block the exploit chain at execution, on systems you cannot patch yet.