Description
A heap-based buffer overflow issue was discovered in libjpeg-turbo in h2v2_merged_upsample_internal() function of jdmrgext.c file. The vulnerability can only be exploited with 12-bit data precision for which the range of the sample data type exceeds the valid sample range, hence, an attacker could craft a 12-bit lossless JPEG image that contains out-of-range 12-bit samples. An application attempting to decompress such image using merged upsampling would lead to segmentation fault or buffer overflows, causing an application to crash.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| — | libjpeg-turbo | Fixed in libjpeg-turbo v3.0 (beta2) | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | libjpeg-turbo | 8.3.2-77.1 | openSUSE-SU-2024:13552-1 |
Alpine
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.24 | libjpeg-turbo | 2.1.5.1-r4 | — |
| Alpine v3.23 | libjpeg-turbo | 2.1.5.1-r4 | — |
| Alpine v3.22 | libjpeg-turbo | 2.1.5.1-r4 | — |
| Alpine v3.21 | libjpeg-turbo | 2.1.5.1-r4 | — |
| Alpine v3.20 | libjpeg-turbo | 2.1.5.1-r4 | — |
Show 2 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Alpine v3.19 | libjpeg-turbo | 2.1.5.1-r4 | — |
| Alpine v3.18 | libjpeg-turbo | 2.1.5.1-r3 | — |
Wolfi
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Wolfi rolling | libjpeg-turbo | 2.1.91-r3 | — |
Advisories 4
- WID-SEC-2026-0369 Microsoft Windows: Mehrere Schwachstellen BSI CERT-Bund (WID) · Mar 26, 2026
- NCSC-2026-0053 Kwetsbaarheden verholpen in Microsoft Windows NCSC-NL (Netherlands) · Feb 10, 2026
- MSRC-CVE-2023-2804 Red Hat, Inc. CVE-2023-2804: Heap Based Overflow libjpeg-turbo Microsoft Security Response Center · Feb 10, 2026
- openSUSE-SU-2024:13552-1 libjpeg-turbo-3.0.1-77.1 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
References
- https://github.com/libjpeg-turbo/libjpeg-turbo/issues/675
- https://bugzilla.redhat.com/show_bug.cgi?id=2208447
- https://access.redhat.com/security/cve/CVE-2023-2804
- https://github.com/libjpeg-turbo/libjpeg-turbo/commit/9f756bc67a84d4566bf74a0c2432aa55da404021
- https://github.com/libjpeg-turbo/libjpeg-turbo/issues/668#issuecomment-1492586118
- https://www.intel.com/content/www/us/en/security-center/advisory/intel-sa-01006.html