# CVE-2022-2085: ghostscript: A NULL pointer dereference vulnerability was found in Ghostscript, which occurs when it tries to render a large numbe...

CVE-2022-2085 is fixed in 17 products on 1 platform, first by ghostscript 9.55.0~dfsg1-0ubuntu5.1, released June 16, 2022. It is not reported as exploited. Patch Radar priority: Routine.

- Web page: https://patchblox.com/security/cve/CVE-2022-2085
- Priority: Routine
- CVSS: 5.5 (medium)
- EPSS: 0.0141
- CISA KEV: not listed
- Exploited (vendor report): no
- Publicly disclosed: no
- Published: Jun 16, 2022

## Description

A NULL pointer dereference vulnerability was found in Ghostscript, which occurs when it tries to render a large number of bits in memory. When allocating a buffer device, it relies on an init_device_procs defined for the device that uses it as a prototype that depends upon the number of bits per pixel. For bpp > 64, mem_x_device is used and does not have an init_device_procs defined. This flaw allows an attacker to parse a large number of bits (more than 64 bits per pixel), which triggers a NULL pointer dereference flaw, causing an application to crash.

## Where it's fixed

| Platform | Product | Fixed in | Fix | Released |
|---|---|---|---|---|
| Linux | ghostscript Debian 12.15 (bookworm) | 9.56.0~dfsg-1 | [DEBIAN-CVE-2022-2085](https://patchblox.com/security/data/fix/linux/debian-cve-2022-2085.md) | Jun 16, 2022 |
| Linux | ghostscript Debian 13.5 (trixie) | 9.56.0~dfsg-1 | [DEBIAN-CVE-2022-2085](https://patchblox.com/security/data/fix/linux/debian-cve-2022-2085.md) | Jun 16, 2022 |
| Linux | ghostscript Debian 14 | 9.56.0~dfsg-1 | [DEBIAN-CVE-2022-2085](https://patchblox.com/security/data/fix/linux/debian-cve-2022-2085.md) | Jun 16, 2022 |
| Linux | ghostscript Ubuntu 22.04.1 LTS (jammy) | 9.55.0~dfsg1-0ubuntu5.1 | [ghostscript 9.55.0~dfsg1-0ubuntu5.1](https://patchblox.com/security/data/fix/linux/ubuntu-jammy-ghostscript-9.55.0-dfsg1-0ubuntu5.1.md) | Jun 16, 2022 |
| Linux | ghostscript amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-debuginfo amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-debugsource amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-doc amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-gtk amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-gtk-debuginfo amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-tools-dvipdf amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-tools-fonts amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-tools-printing amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-x Ubuntu 22.04.1 LTS (jammy) | 9.55.0~dfsg1-0ubuntu5.1 | [ghostscript-x 9.55.0~dfsg1-0ubuntu5.1](https://patchblox.com/security/data/fix/linux/ubuntu-jammy-ghostscript-x-9.55.0-dfsg1-0ubuntu5.1.md) | Jun 16, 2022 |
| Linux | ghostscript-x11 amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | ghostscript-x11-debuginfo amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | libgs amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | libgs-debuginfo amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | libgs-devel amzn 2023 | 9.56.1-5.amzn2023.0.1 | [ALAS2023-2023-053](https://patchblox.com/security/data/fix/linux/alas2023-2023-053.md) | Feb 17, 2023 |
| Linux | libgs9 Ubuntu 22.04.1 LTS (jammy) | 9.55.0~dfsg1-0ubuntu5.1 | [libgs9 9.55.0~dfsg1-0ubuntu5.1](https://patchblox.com/security/data/fix/linux/ubuntu-jammy-libgs9-9.55.0-dfsg1-0ubuntu5.1.md) | Jun 16, 2022 |
| Linux | libgs9-common Ubuntu 22.04.1 LTS (jammy) | 9.55.0~dfsg1-0ubuntu5.1 | [libgs9-common 9.55.0~dfsg1-0ubuntu5.1](https://patchblox.com/security/data/fix/linux/ubuntu-jammy-libgs9-common-9.55.0-dfsg1-0ubuntu5.1.md) | Jun 16, 2022 |

---

Data as of 2026-11-08T00:53:09Z UTC. Source: Patchblox Patch Radar (https://patchblox.com/security/patch-radar). Patchblox finds out-of-date software on Windows, macOS and Linux and updates it through release rings: https://patchblox.com/demo

Free to use with attribution: show "Data: Patchblox Patch Radar" with a link to https://patchblox.com/security/patch-radar. Terms, including what needs a written agreement: https://patchblox.com/security/patch-radar/use-the-data

Product names, logos and trademarks shown on Patch Radar belong to their respective owners. They are used only to identify the software each security fix applies to and to help readers find their platform. Their use does not imply any affiliation with, or endorsement by, those owners, and Patchblox is not affiliated with any of them.
