CVE-2022-27044
High · 8.8CVSS
8.8
EPSS
1.0%
Published
Apr 8, 2022
CISA due date
—
Cloudanix analysis
A bug in an image library can let attackers take over computers when those computers open certain picture files.
- Exploitation
- Requires User Interaction
- Attacker needs
- User Interaction
- Complexity
- Low
- Impact
- Full Compromise
- Component
- Library
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
Buffer overflow in libsixel/src/quant.c:876 allows memory corruption during color quantization of SIXEL image data, potentially enabling arbitrary code execution or application crash.
Why it matters to the business
Applications relying on libsixel for image decoding face elevated risk of remote compromise when processing untrusted files, which can disrupt image-handling workflows and expose sensitive systems until the library is updated.
How an attack unfolds
An attacker crafts a malicious SIXEL image file that triggers the buffer overflow during quantization; when the victim application processes the file, the overflow corrupts memory and can lead to code execution.
How to fix it
Upgrade libsixel to the latest available version that resolves the buffer overflow; if no official fix exists, replace the library with a maintained alternative or isolate affected image-processing components behind strict input validation.
How to confirm the fix worked
Rebuild or scan applications with the updated library and confirm absence of the vulnerable quant.c:876 code path; test processing of known-malicious SIXEL test files to verify no overflow occurs.
Typical attack path
- Attacker creates a specially crafted SIXEL image containing oversized color data
- Malicious image is delivered via email, web download, or file share
- Victim application or library processes the image, invoking quant.c:876
- Buffer overflow occurs, enabling attacker-controlled memory writes
- Attacker achieves code execution or denial of service
How to detect it
Search application and system logs for crashes or segmentation faults while processing SIXEL files; inspect process memory dumps or core files for corruption patterns near color quantization routines.
What your security team should do
- Immediately inventory all systems and containers using libsixel 1.8.6 or earlier
- Block or sanitize untrusted SIXEL image inputs at application entry points
- Monitor upstream project for a security release and deploy it as soon as available
- Add runtime memory-safety tooling where feasible for image-processing pipelines
The record
libsixel 1.8.6 is affected by Buffer Overflow in libsixel/src/quant.c:876.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:11 | libsixel | 0 | No fix |
| Debian:12 | libsixel | 0 | 1.10.3-1 |
| Debian:13 | libsixel | 0 | 1.10.3-1 |
| Ubuntu:16.04:LTS | libsixel | 0 | No fix |
| Ubuntu:18.04:LTS | libsixel | 0 | No fix |
| Ubuntu:20.04:LTS | libsixel | 0 | No fix |
| Ubuntu:22.04:LTS | libsixel | 0 | No fix |
| Ubuntu:24.04:LTS | libsixel | 0 | No fix |
| Ubuntu:24.10 | libsixel | 0 | No fix |
| Ubuntu:25.04 | libsixel | 0 | No fix |
| Ubuntu:25.10 | libsixel | 0 | No fix |
| Ubuntu:Pro:16.04:LTS | libsixel | 0 | No fix |
| Ubuntu:Pro:18.04:LTS | libsixel | 0 | No fix |
| Ubuntu:Pro:20.04:LTS | libsixel | 0 | No fix |
Related vulnerabilities
- CVE-2022-29978 There is a floating point exception error in sixel_encoder_do_resize, encoder.c:633 in… Also affects libsixel
- CVE-2022-29977 There is an assertion failure error in stbi__jpeg_huff_decode, stb_image.h:1894 in… Also affects libsixel
- CVE-2021-40656 libsixel before 1.10 is vulnerable to Buffer Overflow in libsixel/src/quant.c:867. Also affects libsixel
- CVE-2021-41715 libsixel 1.10.0 is vulnerable to Use after free in libsixel/src/dither.c:379. Also affects libsixel
- CVE-2022-27046 libsixel 1.8.6 suffers from a Heap Use After Free vulnerability in in… Also affects libsixel
- CVE-2021-46700 In libsixel 1.8.6, sixel_encoder_output_without_macro (called from… Also affects libsixel
- CVE-2021-45340 In Libsixel prior to and including v1.10.3, a NULL pointer dereference in the stb_image.h… Also affects libsixel
- CVE-2026-111497 A buffer overflow vulnerability in the Brotli decoder (c/dec/decode.c) in Google Brotli… CWE-787