CVE-2025-1022: Improper Input Validation in spatie/browsershot
spatie/browsershot versions before 5.0.5 contain an improper input validation vulnerability in the setHtml function, which can be exploited by bypassing file URI scheme checks. This allows potentially malicious input such as file URIs without proper slashes (e.g., file:../../../../etc/passwd) to be processed. The vulnerability remains unpatched as of the publication date.
AI Analysis
Technical Summary
The vulnerability in spatie/browsershot prior to version 5.0.5 arises from insufficient validation of user input in the setHtml function, invoked via Browsershot::html(). Specifically, the function fails to block file URI schemes properly, allowing attackers to bypass intended restrictions by omitting slashes in the file URI. This improper input validation can lead to unintended file access or processing. Despite identification and proof-of-concept exploits, no official fix or patch has been released yet.
Potential Impact
This vulnerability has a high severity CVSS score of 8.8 and allows remote attackers to bypass input validation controls without authentication or user interaction. The improper handling of file URI schemes could enable attackers to access or manipulate local files or HTML content in unintended ways, potentially leading to information disclosure or other security impacts. No known exploits in the wild have been reported so far.
Mitigation Recommendations
As no official patch or remediation is currently available, developers using spatie/browsershot versions prior to 5.0.5 should implement their own input validation to block or sanitize file URI schemes, including variants that omit slashes. Monitoring vendor advisories for an official fix is recommended. Avoid using vulnerable versions in production environments until a patch is released.
CVE-2025-1022: Improper Input Validation in spatie/browsershot
Description
spatie/browsershot versions before 5.0.5 contain an improper input validation vulnerability in the setHtml function, which can be exploited by bypassing file URI scheme checks. This allows potentially malicious input such as file URIs without proper slashes (e.g., file:../../../../etc/passwd) to be processed. The vulnerability remains unpatched as of the publication date.
CVSS v4.0
Score 8.8high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in spatie/browsershot prior to version 5.0.5 arises from insufficient validation of user input in the setHtml function, invoked via Browsershot::html(). Specifically, the function fails to block file URI schemes properly, allowing attackers to bypass intended restrictions by omitting slashes in the file URI. This improper input validation can lead to unintended file access or processing. Despite identification and proof-of-concept exploits, no official fix or patch has been released yet.
Potential Impact
This vulnerability has a high severity CVSS score of 8.8 and allows remote attackers to bypass input validation controls without authentication or user interaction. The improper handling of file URI schemes could enable attackers to access or manipulate local files or HTML content in unintended ways, potentially leading to information disclosure or other security impacts. No known exploits in the wild have been reported so far.
Mitigation Recommendations
As no official patch or remediation is currently available, developers using spatie/browsershot versions prior to 5.0.5 should implement their own input validation to block or sanitize file URI schemes, including variants that omit slashes. Monitoring vendor advisories for an official fix is recommended. Avoid using vulnerable versions in production environments until a patch is released.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- snyk
- Date Reserved
- 2025-02-04T10:20:48.623Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a57af5d68715ace430250c1
Added to database: 07/15/2026, 16:03:41 UTC
Last enriched: 07/15/2026, 16:17:56 UTC
Last updated: 07/15/2026, 16:17:56 UTC
Views: 3
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.