Skip to main content

CVE-2025-3192: Server-side Request Forgery (SSRF) in spatie/browsershot

High
VulnerabilityCVE-2025-3192cvecve-2025-3192
Published: Fri Apr 04 2025 (04/04/2025, 05:00:11 UTC)
Source: CVE Database V5
Vendor/Project: n/a
Product: spatie/browsershot

Description

Versions of the package spatie/browsershot from 0.0.0 are vulnerable to Server-side Request Forgery (SSRF) in the setUrl() function due to a missing restriction on user input, enabling attackers to access localhost and list all of its directories.

AI-Powered Analysis

AILast updated: 07/09/2025, 01:40:48 UTC

Technical Analysis

CVE-2025-3192 is a high-severity Server-side Request Forgery (SSRF) vulnerability affecting the spatie/browsershot package, specifically in the setUrl() function. Browsershot is a PHP package commonly used to convert web pages into screenshots or PDFs by leveraging headless browsers. The vulnerability arises due to insufficient validation or restriction on user-supplied input URLs passed to the setUrl() function. This lack of input sanitization allows an attacker to craft malicious URLs that the server-side component will fetch, potentially targeting internal network resources such as localhost. Exploiting this vulnerability enables an attacker to perform SSRF attacks, which can lead to unauthorized access to internal services, enumeration of local directories, and potentially further exploitation depending on the internal network configuration. The CVSS 4.0 score of 8.8 reflects the high impact of this vulnerability, with no authentication or user interaction required, and the attack vector being network-based. The vulnerability is identified as CWE-918 (Server-Side Request Forgery). Currently, there are no known exploits in the wild and no patches have been linked yet, indicating that organizations using this package should prioritize mitigation and monitoring. Since the affected version is listed as 0.0.0, it likely refers to all versions up to the first stable release or a specific early version, implying that any deployment using this package without updates is at risk.

Potential Impact

For European organizations, the impact of this SSRF vulnerability can be significant. Organizations using spatie/browsershot in web applications or internal tools may inadvertently expose internal network resources to attackers. This can lead to unauthorized access to sensitive internal services, data leakage, and potential lateral movement within the network. Given the ability to list localhost directories, attackers might gain insights into the server environment, increasing the risk of further exploitation. Critical sectors such as finance, healthcare, and government institutions in Europe, which often rely on PHP-based web applications and internal automation tools, could face data breaches or service disruptions. Additionally, the vulnerability could be leveraged to bypass firewalls or access internal APIs not intended for public exposure, undermining network segmentation and security controls. The absence of required authentication and user interaction makes exploitation easier, increasing the threat level for organizations with internet-facing applications using this package.

Mitigation Recommendations

European organizations should take immediate steps to mitigate this vulnerability. First, identify all instances of spatie/browsershot in their codebases and dependencies. Since no official patch links are provided yet, organizations should consider implementing strict input validation and sanitization on URLs passed to the setUrl() function, restricting requests to trusted domains only. Employ network-level controls such as firewall rules or egress filtering to prevent the server from making unauthorized requests to internal IP ranges, including localhost (127.0.0.1) and private IP spaces. Monitoring and logging outgoing HTTP requests from applications using this package can help detect anomalous SSRF attempts. If possible, isolate the execution environment of browsershot to minimize the impact of potential exploitation. Stay alert for official patches or updates from the package maintainers and apply them promptly once available. Additionally, conduct security reviews and penetration testing focused on SSRF vectors in applications using this package to identify and remediate any exploitation paths.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
snyk
Date Reserved
2025-04-03T09:46:47.272Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 68460b9671f4d251b56ac5dc

Added to database: 6/8/2025, 10:15:50 PM

Last enriched: 7/9/2025, 1:40:48 AM

Last updated: 8/11/2025, 3:40:31 AM

Views: 18

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats