Cloudanix VulnDB

CVE-2025-0624

High · 7.6

CVSS

7.6

EPSS

1.4%

Published

Feb 19, 2025

CISA due date

—

Cloudanix analysis

Monitor only SSVC: Track

A mistake in the boot software that loads the operating system over the network lets someone on the same local network take over the machine before it even starts, defeating security protections that are supposed to stop exactly that.

Exploitation
Adjacent Network
Attacker needs
High Privilege
Complexity
High
Impact
Remote Code Execution
Component
Firmware
Class
Buffer Overflow
Remediation
Upgrade
Effort
Medium
Patch risk
Medium

What it actually does

Out-of-bounds write in grub2 during network boot caused by grub_strcpy copying a user-controlled environment variable into an undersized internal buffer without length validation, enabling remote code execution on the local network segment and secure boot bypass.

Why it matters to the business

Attackers on the same network segment can compromise systems at boot time, bypass secure boot protections, and gain full control before the operating system loads, potentially affecting entire fleets of machines that rely on network boot.

How an attack unfolds

An attacker on the same network segment sets a maliciously long value in the environment variable that grub2 consults while searching for its configuration file during network boot. grub2 then calls grub_strcpy without accounting for the variable's length, triggering an out-of-bounds write that can be leveraged for remote code execution and secure boot bypass.

How to fix it

Update grub2 to a version that correctly bounds the copy operation when reading environment variables during network boot. Rebuild and re-sign any bootloaders or initramfs images that embed the vulnerable grub2 binary. Restrict network boot traffic to trusted segments and disable PXE/TFTP where not required.

How to confirm the fix worked

Verify that the installed grub2 binary reports a version containing the bounds check fix for the environment-variable copy path. Inspect boot loader source or binary for the corrected allocation size calculation before the grub_strcpy call. Test network boot in an isolated environment to confirm the overflow condition no longer occurs.

Typical attack path

  1. Position attacker-controlled system or DHCP/TFTP server on the same network segment as the target boot client
  2. Manipulate the environment variable that grub2 reads during netboot configuration file lookup
  3. Trigger network boot on the target system so grub2 performs the unsafe grub_strcpy copy
  4. Exploit the resulting out-of-bounds write to achieve code execution before the OS kernel loads
  5. Use the foothold to disable or bypass secure boot and persist across reboots

How to detect it

Review bootloader and PXE logs for unexpected environment variable values or unusually long strings passed during configuration file retrieval. Look for boot failures or crashes immediately after the network configuration lookup phase on affected systems.

What your security team should do

  • Apply the grub2 patch immediately on all systems that perform network boot
  • Inventory and prioritize systems using PXE or network boot configurations
  • Segment network boot services behind authenticated or physically controlled networks
  • Monitor for new grub2 releases and integrate them into the standard patching cycle
  • Consider disabling network boot on endpoints that do not require it

The record

A flaw was found in grub2. During the network boot process, when trying to search for the configuration file, grub copies data from a user controlled environment variable into an internal buffer using the grub_strcpy() function. During this step, it fails to consider the environment variable length when allocating the internal buffer, resulting in an out-of-bounds write. If correctly exploited, this issue may result in remote code execution through the same network segment grub is searching for the boot information, which can be used to by-pass secure boot protections.

Affected packages

Ecosystem Package Introduced Fixed
AlmaLinux:8 grub2-common 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-aa64 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-aa64-cdboot 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-aa64-modules 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-ia32 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-ia32-cdboot 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-ia32-modules 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-x64 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-x64-cdboot 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-efi-x64-modules 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-pc 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-pc-modules 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-ppc64le 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-ppc64le-modules 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-tools 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-tools-efi 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-tools-extra 0 1:2.02-162.el8_10.alma.1
AlmaLinux:8 grub2-tools-minimal 0 1:2.02-162.el8_10.alma.1
AlmaLinux:9 grub2-common 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-aa64 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-aa64-cdboot 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-aa64-modules 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-x64 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-x64-cdboot 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-efi-x64-modules 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-pc 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-pc-modules 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-ppc64le 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-ppc64le-modules 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-tools 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-tools-efi 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-tools-extra 0 1:2.06-94.el9_5.alma.1
AlmaLinux:9 grub2-tools-minimal 0 1:2.06-94.el9_5.alma.1
Debian:11 grub2 0 No fix
Debian:12 grub2 0 No fix
Debian:13 grub2 0 No fix
SUSE:Enterprise Storage 7.1 grub2 0 2.04-150300.22.52.3
SUSE:Linux Enterprise High Performance Computing 15 SP3-LTSS grub2 0 2.04-150300.22.52.3
SUSE:Linux Enterprise High Performance Computing 15 SP4-ESPOS grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise High Performance Computing 15 SP4-LTSS grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise High Performance Computing 15 SP5-ESPOS grub2 0 2.06-150500.29.43.2
SUSE:Linux Enterprise High Performance Computing 15 SP5-LTSS grub2 0 2.06-150500.29.43.2
SUSE:Linux Enterprise Micro 5.2 grub2 0 2.04-150300.22.52.3
SUSE:Linux Enterprise Micro 5.3 grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise Micro 5.4 grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise Micro 5.5 grub2 0 2.06-150500.29.43.2
SUSE:Linux Enterprise Module for Basesystem 15 SP6 grub2 0 2.12-150600.8.18.2
SUSE:Linux Enterprise Module for Server Applications 15 SP6 grub2 0 2.12-150600.8.18.2
SUSE:Linux Enterprise Server 12 SP5-LTSS grub2 0 2.02-181.2
SUSE:Linux Enterprise Server 15 SP3-LTSS grub2 0 2.04-150300.22.52.3
SUSE:Linux Enterprise Server 15 SP4-LTSS grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise Server 15 SP5-LTSS grub2 0 2.06-150500.29.43.2
SUSE:Linux Enterprise Server LTSS Extended Security 12 SP5 grub2 0 2.02-181.2
SUSE:Linux Enterprise Server for SAP Applications 15 SP3 grub2 0 2.04-150300.22.52.3
SUSE:Linux Enterprise Server for SAP Applications 15 SP4 grub2 0 2.06-150400.11.55.2
SUSE:Linux Enterprise Server for SAP Applications 15 SP5 grub2 0 2.06-150500.29.43.2
SUSE:Manager Proxy 4.3 grub2 0 2.06-150400.11.55.2
SUSE:Manager Proxy Module 4.3 grub2 0 2.06-150400.11.55.2
SUSE:Manager Server 4.3 grub2 0 2.06-150400.11.55.2
SUSE:Manager Server Module 4.3 grub2 0 2.06-150400.11.55.2
openSUSE:Leap 15.6 grub2 0 2.12-150600.8.18.2
openSUSE:Tumbleweed grub2 0 2.12-35.1

Related vulnerabilities