CVE-2025-1022

High

Description

Versions of the package spatie/browsershot before 5.0.5 are vulnerable to Improper Input Validation in the setHtml function, invoked by Browsershot::html(), which can be bypassed by omitting the slashes in the file URI (e.g., file:../../../../etc/passwd). This is due to missing validations of the user input that should be blocking file URI schemes (e.g., file:// and file:/) in the HTML content. **Note:** Further analysis has identified additional proof-of-concept exploits leveraging the vulnerable function. Developers using this package should ensure proper input validation to mitigate potential risks, as the issue remains unaddressed.

SeverityHigh
CVSS8.2
Exploit probability—
ProductSpatie/browsershot
PublishedFeb 5, 2025
First seenFeb 5, 2025

How to fix

Update
  • spatie/browsershot5.0.5 or later

Affected products

ProductAffected versionsFixed in
spatie/browsershotPackagistv < 5.0.55.0.5

Check your version

Choose the product and enter the version you run to see whether it falls in the affected range.

In the Intelligence 360 plan

Attack Surface Management

See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.