CVE-2021-3695 json
A crafted 16-bit grayscale PNG image may lead to a out-of-bounds write in the heap area.
published 2022-07-06 4 y ago modified 2026-06-17 4 mo ago also EUVD-2021-26980
- cvss
- 4.5
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.5%
- EPSS 0.5% chance of exploitation in 30 days, percentile 41%
- public exploits
- 0
- none known
Summary
A crafted 16-bit grayscale PNG image may lead to a out-of-bounds write in the heap area. An attacker may take advantage of that to cause heap data corruption or eventually arbitrary code execution and circumvent secure boot protections. This issue has a high complexity to be exploited as an attacker needs to perform some triage over the heap layout to achieve signifcant results, also the values written into the memory are repeated three times in a row making difficult to produce valid payloads. This flaw affects grub2 versions prior grub-2.12.
Patch / fix
- gnu grub2 2.12
- grub2 Debian 14, Debian 13, Debian 12 2.06-3
debian advisories DEBIAN-CVE-2021-3695
- grub2-signed Ubuntu 18.04 LTS 1.187.3~18.04.1
- grub2-signed Ubuntu 20.04 LTS 1.187.3~20.04.1
- grub2-signed Ubuntu 22.04 LTS 1.187.3~22.04.1
- grub2-unsigned Ubuntu 22.04 LTS, Ubuntu 20.04 LTS, Ubuntu 18.04 LTS 2.06-2ubuntu14.1
ubuntu advisories UBUNTU-CVE-2021-3695
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- shim-unsigned-x64 RHEL 9 15.6-1.el9
- shim RHEL 9 15.6-1.el9
- grub2 RHEL 9 1:2.06-27.el9_0.7
- grub2-pc RHEL 9 1:2.06-27.el9_0.7
- shim-x64 RHEL 9 15.6-1.el9
- shim-aa64 RHEL 9 15.6-1.el9
- grub2-tools RHEL 9 1:2.06-27.el9_0.7
- grub2-common RHEL 9 1:2.06-27.el9_0.7
red hat advisories RHSA-2022:5099RHSA-2022:5100RHSA-2022:5095RHSA-2022:5096RHSA-2022:5098
- grub2 SLES for SAP 15 SP2, SLES 15 SP2-LTSS, SLES 15 SP2-BCL +6 more 2.04-150200.9.63.2
- grub2 SLE Micro 5.1 2.04-150300.3.5.1
- grub2 SLE Module for Server Applications 15 SP3, SLE Module for Basesystem 15 SP3, SLE Micro 5.2 +2 more 2.04-150300.22.20.2
- grub2 SLES for SAP 15 SP1, SLES 15 SP1-LTSS, SLES 15 SP1-BCL +3 more 2.02-150100.123.12.2
- grub2 SLES 12 SP2-BCL 2.02-115.67.2
- grub2 SLES for SAP 12 SP5, SLES for SAP 12 SP4, SLES 12 SP5 +3 more 2.02-143.2
- grub2 SLES for SAP 12 SP3, SLES 12 SP3-LTSS, SLES 12 SP3-BCL +3 more 2.02-137.2
- grub2 SLES for SAP 15, SLES 15-LTSS, SLE High Performance Computing 15-LTSS +1 more 2.02-150000.122.12.2
suse advisories SUSE-SU-2022:2074-1SUSE-SU-2022:2073-1SUSE-SU-2022:2064-1SUSE-SU-2022:2041-1SUSE-SU-2022:2039-1SUSE-SU-2022:2038-1
- grub2 openSUSE Tumbleweed 2.06-25.1
opensuse advisories openSUSE-SU-2024:12137-1
- shim-unsigned-x64 AlmaLinux 8 15.6-1.el8.alma
- grub2-pc AlmaLinux 8 1:2.02-123.el8_6.8.alma
- shim-x64 AlmaLinux 8 15.6-1.el8.alma
- shim-aa64 AlmaLinux 8 15.6-1.el8.alma
- shim-ia32 AlmaLinux 8 15.6-1.el8.alma
- grub2-tools AlmaLinux 8 1:2.02-123.el8_6.8.alma
- grub2-common AlmaLinux 8 1:2.02-123.el8_6.8.alma
- grub2-efi-x64 AlmaLinux 8 1:2.02-123.el8_6.8.alma
almalinux advisories ALSA-2022:5095ALSA-2022:5099
- shim Rocky Linux 9 15.6-1.el9
- shim Rocky Linux 9 15.6-1.el9.rocky.0.1
- mokutil Rocky Linux 9 2:0.4.0-8.el9_0.1
- shim-unsigned-x64 Rocky Linux 8 15.6-1.el8
- shim Rocky Linux 8 15.6-1.el8
- grub2 Rocky Linux 8 1:2.02-123.el8_6.8
- mokutil Rocky Linux 8 1:0.3.0-11.el8_6.1
rocky linux advisories RLSA-2022:5099RLSA-2022:5095
- grub2 CBL-Mariner 2.0 2.06-12
- grub2 Azure Linux 3.0 2.06-14
azure linux advisories AZL-31034AZL-34783
Azure Linux vulnerability data, Copyright (c) Microsoft Corporation, from https://github.com/microsoft/AzureLinuxVulnerabilityData via OSV, under the MIT licence; changed: normalised to fixed package versions per release. MIT
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2021-3695 updated cvss 7.5
grub2: Crafted PNG grayscale images may lead to out-of-bounds write in heap
-
Red Hat Enterprise Linux 7 grub2, grub2-pc, grub2-efi, grub2-ppc64, grub2-tools, grub2-common, +15 moreaffected: no fix planned “Out of support scope”
-
Red Hat Enterprise Linux BaseOS (v. 8) grub2 2.02-123.el8_6.8, grub2-pc 2.02-123.el8_6.8, grub2-tools 2.02-123.el8_6.8, grub2-common 2.02-123.el8_6.8, grub2-efi-x64 2.02-123.el8_6.8, grub2-ppc64le 2.02-123.el8_6.8, +13 morefixed: vendor fix RHSA-2022:5095
-
Red Hat Enterprise Linux BaseOS (v. 9) grub2 2.06-27.el9_0.7, grub2-pc 2.06-27.el9_0.7, grub2-tools 2.06-27.el9_0.7, grub2-common 2.06-27.el9_0.7, grub2-efi-x64 2.06-27.el9_0.7, grub2-ppc64le 2.06-27.el9_0.7, +10 morefixed: vendor fix RHSA-2022:5099
-
Red Hat Enterprise Linux BaseOS E4S (v. 8.1) grub2 2.02-87.el8_1.10, grub2-pc 2.02-87.el8_1.10, grub2-tools 2.02-87.el8_1.10, grub2-common 2.02-87.el8_1.10, grub2-efi-x64 2.02-87.el8_1.10, grub2-ppc64le 2.02-87.el8_1.10, +11 morefixed: vendor fix RHSA-2022:5098
-
Red Hat Enterprise Linux BaseOS EUS (v. 8.2) grub2 2.02-87.el8_2.10, grub2-pc 2.02-87.el8_2.10, grub2-tools 2.02-87.el8_2.10, grub2-common 2.02-87.el8_2.10, grub2-efi-x64 2.02-87.el8_2.10, grub2-ppc64le 2.02-87.el8_2.10, +13 morefixed: vendor fix RHSA-2022:5100
-
Red Hat Enterprise Linux BaseOS EUS (v.8.4) grub2 2.02-99.el8_4.9, grub2-pc 2.02-99.el8_4.9, grub2-tools 2.02-99.el8_4.9, grub2-common 2.02-99.el8_4.9, grub2-efi-x64 2.02-99.el8_4.9, grub2-ppc64le 2.02-99.el8_4.9, +13 morefixed: vendor fix RHSA-2022:5096
-
Red Hat CodeReady Linux Builder (v. 9) shim-unsigned-x64 15.6-1.el9 Red Hat CodeReady Linux Builder EUS (v. 8.2) shim-unsigned-x64 15.6-1.el8 Red Hat Enterprise Linux BaseOS (v. 8) shim 15.6-1.el8, shim-x64 15.6-1.el8, shim-aa64 15.6-1.el8, shim-ia32 15.6-1.el8, mokutil 0.3.0-11.el8_6.1 Red Hat Enterprise Linux BaseOS (v. 9) shim 15.6-1.el9, shim-x64 15.6-1.el9, shim-aa64 15.6-1.el9, mokutil 0.4.0-8.el9_0.1 Red Hat Enterprise Linux BaseOS E4S (v. 8.1) shim 15.6-1.el8, shim-x64 15.6-1.el8, shim-ia32 15.6-1.el8, mokutil 0.3.0-9.el8_1.1 Red Hat Enterprise Linux BaseOS EUS (v. 8.2) shim 15.6-1.el8, shim-x64 15.6-1.el8, shim-aa64 15.6-1.el8, shim-ia32 15.6-1.el8, mokutil 0.3.0-9.el8_2.2not affected: vulnerable code not present
+3 more productsfewer
Red Hat Enterprise Linux BaseOS EUS (v.8.4) shim 15.6-1.el8, shim-x64 15.6-1.el8, shim-aa64 15.6-1.el8, shim-ia32 15.6-1.el8, mokutil 0.3.0-11.el8_4.1 Red Hat Enterprise Linux CRB (v. 8) shim-unsigned-x64 15.6-1.el8 Red Hat Enterprise Linux CRB EUS (v.8.4) shim-unsigned-x64 15.6-1.el8
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
0.47% chance of exploitation in the next 30 days, higher than 41% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 4.5 | CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:L/I:L/A:L |
| NVD | 2.0 | 4.4 | AV:L/AC:M/Au:N/C:P/I:P/A:P |
Affected products
- n/a grub2
Classification
- Weakness
-
- CWE-787 Out-of-bounds Write
References
-
security.gentoo.org
/glsa/202209-12
vendor-advisory, third-party-advisory
-
bugzilla.redhat.com
/show_bug.cgi?id=1991685
issue-tracking, third-party-advisory
-
security.netapp.com
/advisory/ntap-20220930-0001/
third-party-advisory
Sources
- CVE List CVE-2021-3695
- NVD CVE-2021-3695
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.