Heap-based buffer overflow in GhostPDL - CVE-2021-45949
Published: January 8, 2022
Vulnerability details
The vulnerability allows a remote attacker to execute arbitrary code on the target system.
The vulnerability exists due to a boundary error within the sampled_data_finish() function (called from sampled_data_continue and interp). A remote attacker can create a specially crafted file, trick the victim into opening it, trigger heap-based buffer overflow and execute arbitrary code on the target system.
Successful exploitation of this vulnerability may result in complete compromise of vulnerable system.
Affected software
ghostscript (Debian package)
libgs9 (Ubuntu package)
ghostscript (Ubuntu package)
ghostscript-help
ghostscript-debuginfo
ghostscript-debugsource
ghostscript-tools-dvipdf
ghostscript-devel
ghostscript
ghostscript-x11-debuginfo
ghostscript-x11
SUSE Linux Enterprise Software Development Kit
SUSE Linux Enterprise Server
SUSE Linux Enterprise Realtime Extension
SUSE Linux Enterprise Module for Basesystem
Ubuntu
openEuler
How to mitigate CVE-2021-45949
ghostscript (Debian package) - addressed in versions 9.27~dfsg-2+deb10u5, 9.53.3~dfsg-7+deb11u2
libgs9 (Ubuntu package) - addressed in versions 9.26~dfsg+00ubuntu0.16.04.14+esm1, 9.26~dfsg+0-0ubuntu0.18.04.15, 9.50~dfsg-5ubuntu4.5, 9.53.3~dfsg-7ubuntu0.2, 9.54.0~dfsg1-0ubuntu2.1
ghostscript (Ubuntu package) - addressed in versions 9.26~dfsg+00ubuntu0.16.04.14+esm1, 9.26~dfsg+0-0ubuntu0.18.04.15, 9.50~dfsg-5ubuntu4.5, 9.53.3~dfsg-7ubuntu0.2, 9.54.0~dfsg1-0ubuntu2.1
ghostscript-help - update to 9.52-5
ghostscript-debuginfo - update to 9.52-5
ghostscript-debugsource - update to 9.52-5
ghostscript-tools-dvipdf - update to 9.52-5
ghostscript-devel - update to 9.52-5
ghostscript - update to 9.52-5
ghostscript-x11-debuginfo - addressed in versions 9.52-23.48.1, 9.52-161.1
ghostscript-debugsource - addressed in versions 9.52-23.48.1, 9.52-161.1
ghostscript-devel - addressed in versions 9.52-23.48.1, 9.52-161.1
ghostscript - addressed in versions 9.52-23.48.1, 9.52-161.1
ghostscript-x11 - addressed in versions 9.52-23.48.1, 9.52-161.1
ghostscript-debuginfo - addressed in versions 9.52-23.48.1, 9.52-161.1