Stack Buffer Underflow Vulnerability in Ghostscript
Summary
OSV-2025-63: Stack-buffer-underflow in gs_type1_interpret. Affects ghostscript versions >= 171b0c9a4c04aba37e9638e356865df61b108655, < 329fa492271566a43f905edafb83dbce1b01a62a. Fixed in 329fa492271566a43f905edafb83dbce1b01a62a. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
Ghostscript is an interpreter for the PostScript language and for PDF. It is widely used for processing and rendering documents in various formats. The software is known for its ability to convert files between different formats and is utilized in many applications for printing and document management. However, like many complex software systems, it is susceptible to vulnerabilities that can compromise its functionality and security.
Vulnerability Detail
The vulnerability identified as OSV-2025-63 is a stack-buffer-underflow issue occurring in the function gs_type1_interpret. This flaw can lead to unexpected behavior, including potential crashes or exploitation by attackers. The vulnerability was reported through OSS-Fuzz, indicating that it was discovered during fuzz testing, which is a common method for identifying security flaws in software. The specific crash state involves a read operation that accesses memory outside the intended bounds, which can lead to data corruption or unauthorized access.
How To Fix
Minimum fixed version
329fa492271566a43f905edafb83dbce1b01a62a
This is the first release that contains the fix.
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
Currently, there are no specific workarounds mentioned for this vulnerability. Users are advised to apply the patch as soon as it is available to mitigate any risks associated with the vulnerability.
Conclusion
The stack-buffer-underflow vulnerability in Ghostscript poses significant risks to users, including potential crashes and unauthorized access. It is crucial for users to update to the latest patched version to mitigate these risks. Utilizing tools like Vulert can help monitor for such vulnerabilities effectively.
See every vulnerability recorded for ghostscript →
FAQ
A stack-buffer-underflow vulnerability occurs when a program reads data from a memory location that is before the start of a buffer, potentially leading to crashes or exploitation.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software. By simply uploading your manifest file like package-lock.json, you can check for vulnerabilities without needing to install any software.
If exploited, this vulnerability could lead to application crashes, data corruption, or unauthorized access to sensitive information.
Yes, users should update to the version fixed after commit 329fa492271566a43f905edafb83dbce1b01a62a to ensure they are protected against this vulnerability.
It is recommended to regularly check for updates, ideally on a weekly basis, to ensure that all known vulnerabilities are patched promptly.
References
Related vulnerabilities
Recent vulnerabilities recorded for ghostscript.