Cloudanix VulnDB

CVE-2024-46951

None

CVSS

—

EPSS

0.4%

Published

Nov 10, 2024

CISA due date

—

Cloudanix analysis

Monitor only SSVC: Track

A bug in the software that processes PDF and PostScript files can let attackers run their own programs when a specially crafted document is opened.

Exploitation
Requires User Interaction
Attacker needs
User Interaction
Complexity
Moderate
Impact
Remote Code Execution
Component
Library
Class
Memory Corruption
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

Unchecked Implementation pointer dereference in Pattern color space handling within psi/zcolor.c allows out-of-bounds memory access and potential control-flow hijacking leading to arbitrary code execution.

Why it matters to the business

Attackers could execute arbitrary code on systems that render or process untrusted PostScript and PDF documents, risking compromise of document conversion, printing, and preview pipelines with potential data theft or malware deployment.

How an attack unfolds

An attacker supplies a crafted PDF or PostScript file containing a malformed Pattern color space object; when Ghostscript parses the color space the unchecked pointer is dereferenced, corrupting memory and allowing the attacker to redirect execution to attacker-controlled code.

How to fix it

Upgrade Artifex Ghostscript to version 10.04.0 or later; the specific fix is present in commit df8f4966577fff70320be2eb33cb55eb15d05d52. Rebuild any downstream packages that embed Ghostscript and validate the updated binary reports version 10.04.0 or newer.

How to confirm the fix worked

Execute 'gs --version' and confirm output is 10.04.0 or greater; run regression test suites against sample Pattern color space files and verify no crashes or unexpected behavior occur on previously vulnerable inputs.

Typical attack path

  1. Deliver malicious PDF/PostScript via email, web download, or shared file
  2. Victim application invokes Ghostscript to interpret or rasterize the document
  3. Parser reaches Pattern color space handling and dereferences the invalid Implementation pointer
  4. Memory corruption is leveraged to achieve code execution within the Ghostscript process
  5. Attacker payload establishes persistence or exfiltrates data from the compromised host

How to detect it

Review process execution logs and file-access telemetry for Ghostscript invocations against untrusted documents; look for crashes or segmentation faults in gs or ghostscript processes around the time of document processing.

What your security team should do

  • Immediately update all Ghostscript installations to 10.04.0 or later
  • Inventory and replace any embedded or statically linked copies of Ghostscript in third-party applications
  • Restrict Ghostscript invocation to trusted input sources until patching is complete
  • Monitor EPSS and KEV status for any future increase in exploit activity

The record

An issue was discovered in psi/zcolor.c in Artifex Ghostscript before 10.04.0. An unchecked Implementation pointer in Pattern color space could lead to arbitrary code execution.

Affected packages

Ecosystem Package Introduced Fixed
AlmaLinux:8 ghostscript 0 9.27-16.el8_10
AlmaLinux:8 ghostscript-doc 0 9.27-16.el8_10
AlmaLinux:8 ghostscript-tools-dvipdf 0 9.27-16.el8_10
AlmaLinux:8 ghostscript-tools-fonts 0 9.27-16.el8_10
AlmaLinux:8 ghostscript-tools-printing 0 9.27-16.el8_10
AlmaLinux:8 ghostscript-x11 0 9.27-16.el8_10
AlmaLinux:8 libgs 0 9.27-16.el8_10
AlmaLinux:8 libgs-devel 0 9.27-16.el8_10
AlmaLinux:9 ghostscript 0 9.54.0-18.el9_6
AlmaLinux:9 ghostscript-doc 0 9.54.0-18.el9_6
AlmaLinux:9 ghostscript-tools-dvipdf 0 9.54.0-18.el9_6
AlmaLinux:9 ghostscript-tools-fonts 0 9.54.0-18.el9_6
AlmaLinux:9 ghostscript-tools-printing 0 9.54.0-18.el9_6
AlmaLinux:9 ghostscript-x11 0 9.54.0-18.el9_6
AlmaLinux:9 libgs 0 9.54.0-18.el9_6
AlmaLinux:9 libgs-devel 0 9.54.0-18.el9_6
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