CVE-2024-46955
NoneCVSS
—
EPSS
0.3%
Published
Nov 10, 2024
CISA due date
—
Cloudanix analysis
A flaw in the Ghostscript software used to handle documents can let attackers peek at memory they should not see or crash the program when opening certain files.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Moderate
- Impact
- Data Exposure
- Component
- Library
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Out-of-bounds read in psi/zcolor.c when processing color values in an Indexed color space, allowing access to adjacent memory regions during PostScript/PDF rendering.
Why it matters to the business
Processing untrusted documents can cause application crashes or unintended memory disclosure, disrupting document workflows and potentially exposing sensitive data in environments that rely on Ghostscript for rendering or conversion.
How an attack unfolds
An attacker creates a crafted PDF or PostScript file containing an improperly defined Indexed color space. When Ghostscript parses the color lookup table, the out-of-bounds read occurs, potentially leaking memory contents or triggering a crash that an attacker could leverage for further attacks.
How to fix it
Upgrade Artifex Ghostscript / GhostPDL to the version containing commit df8f4966577fff70320be2eb33cb55eb15d05d52 (equivalent to 10.04.0 or later). Rebuild any dependent packages and restart services that invoke Ghostscript for document processing.
How to confirm the fix worked
Confirm the installed Ghostscript binary reports version 10.04.0 or newer, or verify the source tree contains commit df8f4966577fff70320be2eb33cb55eb15d05d52. Test rendering of sample files containing Indexed color spaces to ensure no crashes occur.
Typical attack path
- Attacker crafts a malicious PDF or PostScript document with malformed Indexed color space data
- Document is delivered to the target via email, web download, or file share
- Victim or automated process opens the document using Ghostscript or a dependent application
- Ghostscript parses the color space in zcolor.c, triggering the out-of-bounds read
- Attacker observes crash or extracts leaked memory to advance the attack
How to detect it
Review application logs for Ghostscript crashes or segmentation faults during PDF/PostScript processing. Monitor for unexpected memory usage spikes or error messages referencing color space handling in zcolor.c. No public exploitation artifacts are known.
What your security team should do
- Immediately update all Ghostscript installations to the fixed commit or 10.04.0 release
- Scan internal repositories and build pipelines for older Ghostscript versions
- Add Ghostscript version checks to vulnerability scanning and software bill-of-materials processes
- Restrict Ghostscript execution to trusted input sources until patches are applied
The record
An issue was discovered in psi/zcolor.c in Artifex Ghostscript before 10.04.0. There is an out-of-bounds read when reading color in Indexed color space.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Alpine:v3.18 | ghostscript | 0 | 10.04.0-r0 |
| Alpine:v3.19 | ghostscript | 0 | 10.04.0-r0 |
| Alpine:v3.20 | ghostscript | 0 | 10.04.0-r0 |
| Alpine:v3.21 | ghostscript | 0 | 10.04.0-r0 |
| Alpine:v3.22 | ghostscript | 0 | 10.04.0-r0 |
| Debian:11 | ghostscript | 0 | No fix |
| Debian:11 | ghostscript | 0 | 9.53.3~dfsg-7+deb11u9 |
| Debian:12 | ghostscript | 0 | No fix |
| Debian:12 | ghostscript | 0 | 10.0.0~dfsg-11+deb12u6 |
| Debian:13 | ghostscript | 0 | 10.04.0~dfsg-1 |
| Debian:14 | ghostscript | 0 | 10.04.0~dfsg-1 |
| Mageia:9 | ghostscript | 0 | 10.04.0-1.mga9 |
| SUSE:Enterprise Storage 7.1 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP2-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP3-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise High Performance Computing 15 SP4-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP5 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Module for Basesystem 15 SP6 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server 12 SP5-LTSS | ghostscript | 0 | 9.52-23.86.1 |
| SUSE:Linux Enterprise Server 15 SP2-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server 15 SP3-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server 15 SP4-LTSS | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server LTSS Extended Security 12 SP5 | ghostscript | 0 | 9.52-23.86.1 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP2 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP3 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Linux Enterprise Server for SAP Applications 15 SP4 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Manager Proxy 4.3 | ghostscript | 0 | 9.52-150000.200.1 |
| SUSE:Manager Server 4.3 | ghostscript | 0 | 9.52-150000.200.1 |
| Ubuntu:20.04:LTS | ghostscript | 0 | 9.50~dfsg-5ubuntu4.14 |
| Ubuntu:22.04:LTS | ghostscript | 0 | 9.55.0~dfsg1-0ubuntu5.10 |
| Ubuntu:24.04:LTS | ghostscript | 0 | 10.02.1~dfsg1-0ubuntu7.4 |
| Ubuntu:24.10 | ghostscript | 0 | 10.03.1~dfsg1-0ubuntu2.1 |
| Ubuntu:Pro:16.04:LTS | ghostscript | 0 | 9.26~dfsg+0-0ubuntu0.16.04.14+esm8 |
| Ubuntu:Pro:18.04:LTS | ghostscript | 0 | 9.26~dfsg+0-0ubuntu0.18.04.18+esm3 |
| openSUSE:Leap 15.5 | ghostscript | 0 | 9.52-150000.200.1 |
| openSUSE:Leap 15.6 | ghostscript | 0 | 9.52-150000.200.1 |
| openSUSE:Tumbleweed | ghostscript | 0 | 10.04.0-1.1 |
Related vulnerabilities
- CVE-2025-27837 An issue was discovered in Artifex Ghostscript before 10.05.0. Also affects ghostscript
- CVE-2024-46956 An issue was discovered in psi/zfile.c in Artifex Ghostscript before 10.04.0. Also affects ghostscript
- CVE-2024-46953 An issue was discovered in base/gsdevice.c in Artifex Ghostscript before 10.04.0. Also affects ghostscript
- CVE-2024-46954 An issue was discovered in decode_utf8 in base/gp_utf8.c in Artifex Ghostscript before… Also affects ghostscript
- CVE-2024-46952 An issue was discovered in pdf/pdf_xref.c in Artifex Ghostscript before 10.04.0. Also affects ghostscript
- CVE-2024-46951 An issue was discovered in psi/zcolor.c in Artifex Ghostscript before 10.04.0. Also affects ghostscript
- CVE-2023-52722 An issue was discovered in Artifex Ghostscript before 10.03.1. Also affects ghostscript
- CVE-2017-8291 Artifex Ghostscript through 2017-04-26 allows -dSAFER bypass and remote command execution… Also affects ghostscript