The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2020-15900

CVE-2020-15900: Ghostscript Privilege Escalation Flaw

CVE-2020-15900 is a privilege escalation vulnerability in Artifex Ghostscript affecting versions 9.50 and 9.52. The flaw allows attackers to override file access controls through memory corruption.

Published: March 4, 2026

CVE-2020-15900 Overview

A critical memory corruption vulnerability was discovered in Artifex Ghostscript versions 9.50 and 9.52. The flaw exists in the rsearch PostScript operator implementation within psi/zstring.c, where an incorrect size calculation can cause an integer underflow. When calculating the 'post' size, the result could be too large and underflow to the maximum uint32_t value, leading to memory corruption. This vulnerability can be exploited through maliciously crafted PostScript files to override file access controls.

Critical Impact

This integer underflow vulnerability allows attackers to corrupt memory and potentially override file access controls through specially crafted PostScript documents, enabling remote code execution without authentication.

Affected Products

  • Artifex Ghostscript 9.50
  • Artifex Ghostscript 9.52
  • Canonical Ubuntu Linux 20.04 LTS
  • openSUSE Leap 15.1
  • openSUSE Leap 15.2

Discovery Timeline

  • 2020-07-28 - CVE-2020-15900 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2020-15900

Vulnerability Analysis

The vulnerability resides in the PostScript interpreter's handling of the rsearch operator in the psi/zstring.c source file. The root issue is an integer underflow condition that occurs during size calculations for string operations. When the rsearch operator processes specially crafted input, the calculation for the 'post' size can produce a value that exceeds expected bounds. This miscalculation causes the size to underflow to the maximum uint32_t value (4,294,967,295), resulting in severe memory corruption.

The impact is significant because Ghostscript is widely deployed as a document processing engine, used by printing systems, document conversion tools, and PDF viewers. An attacker can exploit this vulnerability by convincing a user or automated system to process a malicious PostScript or PDF file. Successful exploitation could lead to arbitrary code execution with the privileges of the Ghostscript process, potentially compromising the entire system.

Root Cause

The vulnerability stems from improper integer arithmetic in the rsearch function within psi/zstring.c. The original code used r_set_size() for size assignments without proper bounds checking. The size calculation for the 'post' portion of the search result could produce a negative value when specific string patterns were matched, which when cast to an unsigned integer would wrap around to an extremely large value. This is classified as CWE-191 (Integer Underflow).

Attack Vector

The attack vector is network-based, requiring no authentication or user interaction beyond file processing. An attacker can deliver a malicious PostScript file through various channels:

  1. Email attachments containing crafted PS or PDF files
  2. Web-based document preview systems
  3. Print servers processing untrusted documents
  4. Automated document conversion pipelines

The malicious PostScript file would contain a non-standard operator sequence designed to trigger the integer underflow in the rsearch calculation, corrupting memory and potentially allowing arbitrary code execution.

c
// Security patch from psi/zstring.c
// Source: https://github.com/ArtifexSoftware/ghostpdl/commit/5d499272b95a6b890a1397e11d20937de000d31b

    return 0;
found:
    op->tas.type_attrs = op1->tas.type_attrs;
-    op->value.bytes = ptr;
-    r_set_size(op, size);
+    op->value.bytes = ptr;				/* match */
+    op->tas.rsize = size;				/* match */
    push(2);
-    op[-1] = *op1;
-    r_set_size(op - 1, ptr - op[-1].value.bytes);
-    op1->value.bytes = ptr + size;
-    r_set_size(op1, count + (!forward ? (size - 1) : 0));
+    op[-1] = *op1;					/* pre */
+    op[-3].value.bytes = ptr + size;			/* post */
+    if (forward) {
+        op[-1].tas.rsize = ptr - op[-1].value.bytes;	/* pre */
+        op[-3].tas.rsize = count;			/* post */
+    } else {
+        op[-1].tas.rsize = count;			/* pre */
+        op[-3].tas.rsize -= count + size;		/* post */
+    }
    make_true(op);
    return 0;
}

The patch replaces the vulnerable r_set_size() calls with direct assignments to tas.rsize and introduces conditional logic to handle forward and reverse search directions separately, preventing the integer underflow condition.

Detection Methods for CVE-2020-15900

Indicators of Compromise

  • Unexpected Ghostscript process crashes or segmentation faults during document processing
  • Anomalous memory allocation patterns in Ghostscript processes
  • PostScript files containing unusual rsearch operator sequences with large string parameters
  • Suspicious PDF or PS files from untrusted sources triggering document conversion failures

Detection Strategies

  • Monitor for Ghostscript process crashes with memory corruption signatures in system logs
  • Implement file integrity monitoring for systems running vulnerable Ghostscript versions
  • Deploy network-based detection rules to identify malicious PostScript content patterns
  • Review process execution logs for unexpected child processes spawned by Ghostscript

Monitoring Recommendations

  • Enable verbose logging for document processing pipelines to capture Ghostscript errors
  • Implement endpoint detection monitoring for memory corruption exploitation techniques
  • Configure SIEM alerts for repeated Ghostscript failures from specific sources
  • Monitor system call patterns from Ghostscript processes for anomalous behavior

How to Mitigate CVE-2020-15900

Immediate Actions Required

  • Update Artifex Ghostscript to version 9.53 or later immediately
  • Apply available security patches from distribution repositories (Ubuntu USN-4445-1, Gentoo GLSA-202008-20, openSUSE security advisories)
  • Restrict Ghostscript from processing untrusted documents until patched
  • Consider sandboxing Ghostscript processes to limit exploitation impact

Patch Information

The vulnerability was fixed in Ghostscript commit 5d499272b95a6b890a1397e11d20937de000d31b. Organizations should update to Ghostscript version 9.53 or later, which includes this security fix. Distribution-specific patches are available:

  • Artifex Security Advisory
  • Ubuntu Security Notice USN-4445-1
  • Gentoo GLSA Advisory
  • GitHub Security Commit

Workarounds

  • Configure Ghostscript with -dSAFER mode to restrict file operations until patching is possible
  • Implement input validation to block PostScript files from untrusted sources
  • Use application sandboxing (containers, AppArmor, SELinux) to isolate Ghostscript processes
  • Disable automatic document preview functionality that relies on Ghostscript
bash
# Configuration example - Running Ghostscript in safer mode
gs -dSAFER -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=output.pdf input.ps

# Verify Ghostscript version (should be 9.53 or later)
gs --version

# Check for vulnerable versions in package manager (Debian/Ubuntu)
apt list --installed 2>/dev/null | grep ghostscript

# Check for vulnerable versions (RHEL/CentOS)
rpm -qa | grep ghostscript

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechArtifex Ghostscript

  • SeverityCRITICAL

  • CVSS Score9.8

  • EPSS Probability2.71%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-191
  • Technical References
  • Ghostscript Repository Log

  • openSUSE Security Announcement

  • openSUSE Security Announcement

  • Ghostscript Commit Diff

  • Gentoo GLSA Advisory

  • Ubuntu Security Notice
  • Vendor Resources
  • Artifex Security Advisory

  • GitHub Ghostscript Commit

  • GitHub Ghostscript Commits
  • Related CVEs
  • CVE-2024-29510: Artifex Ghostscript Privilege Escalation

  • CVE-2023-36664: Artifex Ghostscript Privilege Escalation

  • CVE-2024-46953: Ghostscript Path Traversal Vulnerability

  • CVE-2025-27836: Artifex Ghostscript Buffer Overflow Flaw
Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English