diff --git a/src/boot/efi/boot.c b/src/boot/efi/boot.c index efc6799b00f..8caa6001724 100644 --- a/src/boot/efi/boot.c +++ b/src/boot/efi/boot.c @@ -2373,7 +2373,9 @@ static EFI_STATUS image_start( if (err != EFI_SUCCESS) return log_error_status(err, "Error loading %ls: %m", entry->loader); - if (entry->devicetree) { + /* DTBs are loaded by the kernel before ExitBootServices, and they can be used to map and assign + * arbitrary memory ranges, so skip it when secure boot is enabled as the DTB here is unverified. */ + if (entry->devicetree && !secure_boot_enabled()) { err = devicetree_install(&dtstate, image_root, entry->devicetree); if (err != EFI_SUCCESS) return log_error_status(err, "Error loading %ls: %m", entry->devicetree);