Buffer Overflow Vulnerability in Ghostscript Package: CVE-2024-46952

ghostscript Updated 03 Oct 2025

Summary

30/10/2024
N/A
Yes i
High
7.8

UBUNTU-CVE-2024-46952: An issue was discovered in pdf/pdf_xref.c in Artifex Ghostscript before 10.04.0. Affects ghostscript versions < 9.55.0~dfsg1-0ubuntu5.10. Fixed in 9.55.0~dfsg1-0ubuntu5.10. How to fix ↓

Free scan

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.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Ghostscript is an interpreter for the PostScript language and for PDF. It is widely used for processing and rendering PDF files and is an essential tool for many applications that require document manipulation. The package is known for its versatility and is commonly integrated into various software solutions. However, it has recently been identified as vulnerable to a buffer overflow issue, which could potentially lead to severe security risks.

Vulnerability Detail

An issue was discovered in the pdf/pdf_xref.c file of Artifex Ghostscript before version 10.04.0. This vulnerability involves a buffer overflow that occurs during the handling of a PDF XRef stream, specifically related to W array values. If exploited, this could allow an attacker to execute arbitrary code, leading to unauthorized access or system compromise. The vulnerability has been assigned a CVSS score of 7.8, indicating a high severity level.

How To Fix

Minimum fixed version

9.55.0~dfsg1-0ubuntu5.10

This is the first release that contains the fix.

sudo apt-get install --only-upgrade ghostscript

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary measure, users can limit the use of Ghostscript for processing untrusted PDF files until the package is updated. Additionally, consider using alternative PDF processing tools that do not exhibit this vulnerability.

Conclusion

The Ghostscript package has a critical vulnerability (CVE-2024-46952) that poses significant security risks. Users are strongly advised to update to the latest patched versions to protect their systems from potential exploitation. Utilizing tools like Vulert can help monitor and alert for such vulnerabilities in real-time.

See every vulnerability recorded for ghostscript →

Share this vulnerability

FAQ

CVE-2024-46952 is a buffer overflow vulnerability found in the Ghostscript package, which can lead to arbitrary code execution.

You can use Vulert's playground at Vulert Scanner to check if your application is impacted by this vulnerability without any signup.

If exploited, this vulnerability could allow attackers to execute arbitrary code, potentially compromising the system and leading to data breaches.

Yes, patched versions of Ghostscript are available for both Ubuntu 22.04 LTS and 24.04 LTS. Users should update to the specified versions to mitigate the risk.

If immediate updating is not possible, avoid processing untrusted PDF files and consider using alternative tools until the update can be applied.

Related vulnerabilities

Recent vulnerabilities recorded for ghostscript.

How To Fix

Minimum fixed version

9.55.0~dfsg1-0ubuntu5.10

This is the first release that contains the fix.

sudo apt-get install --only-upgrade ghostscript

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback