# CVE-2021-3781

- Priority: **Prioritise**
- Reason: Severe, CVSS 9.9 (NVD); no exploitation reported by the 5 checked sources; EPSS 86% (FIRST, 04-12-2026)
- Next step: Check applicability and the vendor advisory: no fix release is recorded here
- Status: published
- Published: 2022-02-16 · Modified: 2024-08-03
- Aliases: ALPINE-CVE-2021-3781, MGASA-2021-0436, SUSE-SU-2021:3044-1, SUSE-SU-2021:3180-1, UBUNTU-CVE-2021-3781, USN-5075-1, DEBIAN-CVE-2021-3781, DSA-4972-1, openSUSE-SU-2021:1273-1, openSUSE-SU-2021:3044-1
- Record: https://cvemate.com/vulnerability/CVE-2021-3781 · JSON: https://cvemate.com/vulnerability/CVE-2021-3781/json

## Description

```text
A trivial sandbox (enabled with the `-dSAFER` option) escape flaw was found in the ghostscript interpreter by injecting a specially crafted pipe command. This flaw allows a specially crafted document to execute arbitrary commands on the system in the context of the ghostscript interpreter. The highest threat from this vulnerability is to confidentiality, integrity, as well as system availability.
```

## Signals

- CVSS: 9.9 critical (v3.1, NVD) CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
- EPSS: 85.639%, percentile 99.724%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 69)

- alpine ghostscript (Alpine Linux): \< 9.53.3-r1 \| \< 9.54-r1
- artifex ghostscript: 9.50 \| 9.52 \| 9.53.3 \| 9.54.0
- debian ghostscript (Debian): \< 9.53.3~dfsg-8 \| \< 9.53.3~dfsg-7+deb11u1
- ubuntu ghostscript (Ubuntu): \< 9.50~dfsg-5ubuntu4.3 \| \< 9.54.0~dfsg1-0ubuntu2
- fedoraproject fedora: 34
- mageia ghostscript (Mageia): \< 9.53.3-2.1.mga8
- opensuse ghostscript-mini&distro=openSUSE Leap 15.2 (openSUSE): \< 9.52-lp152.2.7.1
- opensuse ghostscript&distro=openSUSE Leap 15.2 (openSUSE): \< 9.52-lp152.2.7.1
- opensuse ghostscript&distro=openSUSE Leap 15.3 (openSUSE): \< 9.52-155.1
- opensuse libspectre&distro=openSUSE Leap 15.2 (openSUSE): \< 0.2.8-lp152.4.3.1
- opensuse libspectre&distro=openSUSE Leap 15.3 (openSUSE): \< 0.2.8-3.12.1
- suse ghostscript&distro=HPE Helion OpenStack 8 (SUSE Linux Enterprise): \< 9.52-23.42.1
- suse ghostscript&distro=SUSE Enterprise Storage 6 (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise High Performance Computing 15 SP1-ESPOS (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise High Performance Computing 15 SP1-LTSS (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise High Performance Computing 15-ESPOS (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise High Performance Computing 15-LTSS (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise Module for Basesystem 15 SP2 (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise Module for Basesystem 15 SP3 (SUSE Linux Enterprise): \< 9.52-155.1
- suse ghostscript&distro=SUSE Linux Enterprise Server 12 SP2-BCL (SUSE Linux Enterprise): \< 9.52-23.42.1

## References

- <https://bugzilla.redhat.com/show_bug.cgi?id=2002271>
- <https://ghostscript.com/CVE-2021-3781.html>
- <https://security.gentoo.org/glsa/202211-11>
- <https://security.alpinelinux.org/vuln/CVE-2021-3781>
- <https://advisories.mageia.org/MGASA-2021-0436.html>
- <https://bugs.mageia.org/show_bug.cgi?id=29453>
- <https://ubuntu.com/security/notices/USN-5075-1>
- <https://www.debian.org/security/2021/dsa-4972>
- <https://bugs.ghostscript.com/show_bug.cgi?id=704342>
- <https://therecord.media/ghostscript-zero-day-allows-full-server-compromises>
- <https://lists.opensuse.org/archives/list/security-announce@lists.opensuse.org/thread/M64NXCVRRUDYD4U65CYH2ROCOGMSYF3U/>
- <https://www.suse.com/support/update/announcement/2021/suse-su-20213044-1/>
- <https://bugzilla.suse.com/1184123>
- <https://bugzilla.suse.com/1190381>
- <https://www.suse.com/security/cve/CVE-2021-3781>
- <https://www.suse.com/support/update/announcement/2021/suse-su-20213180-1/>
- <https://ubuntu.com/security/CVE-2021-3781>
- <https://www.cve.org/CVERecord?id=CVE-2021-3781>
- <https://security-tracker.debian.org/tracker/CVE-2021-3781>
- <https://lists.opensuse.org/archives/list/security-announce@lists.opensuse.org/thread/H36LVLBVTFLQTYOKRPFVWGCDCWJQWKLY/>

---

Data as of 2026-12-05T11:03:22.873Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
