CVE-2023-40549
NixOS vulnerability analysis and mitigation

Overview

CVE-2023-40549 is an out-of-bounds read vulnerability discovered in the Shim bootloader. The vulnerability exists in the verify_buffer_authenticode() function in shim.c due to the lack of proper boundary verification during the load of a PE binary. This vulnerability was disclosed on January 29, 2024, affecting various versions of Shim up to (excluding) version 15.8 (NVD, Red Hat).

Technical details

The vulnerability stems from an out-of-bounds read issue in the verify_buffer_authenticode() function in shim.c, where a pointer offset is added and accessed without proper bounds checking. The issue is triggered when processing malformed PE files and occurs before signature validation of the PE file. The vulnerability has been assigned a CVSS v3.1 base score of 5.5 (Medium) by NIST and 6.2 (Medium) by Red Hat (NVD).

Impact

When exploited, this vulnerability allows an attacker to load a crafted PE binary, which can trigger the issue and crash Shim, resulting in a denial of service condition. This is particularly concerning for systems using Secure Boot, as Shim is a critical component in the secure boot process (NVD).

Mitigation and workarounds

The vulnerability has been fixed in Shim version 15.8. Red Hat has released security updates for various versions of their Enterprise Linux distributions. It's important to note that when updating Shim, GRUB2 must also be updated simultaneously or before Shim, as the new version revokes all previous versions of GRUB2. Failure to update GRUB2 could result in an unbootable system (Red Hat).

Additional resources


SourceThis report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-68120MEDIUM5.4
  • NixOSNixOS
  • go
NoYesDec 30, 2025
CVE-2025-69413MEDIUM5.3
  • NixOSNixOS
  • code.gitea.io/gitea
NoYesJan 01, 2026
CVE-2025-15412MEDIUM4.8
  • NixOSNixOS
  • wabt
NoNoJan 01, 2026
CVE-2025-15411MEDIUM4.8
  • NixOSNixOS
  • wabt
NoNoJan 01, 2026
CVE-2025-68932LOW2.9
  • NixOSNixOS
  • freshrss
NoYesDec 27, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management