fix not verifying grub.cfg when loading it
Signed-off-by: Qiumiao Zhang <zhangqiumiao1@huawei.com>
This commit is contained in:
parent
6624b981b1
commit
3fff9f95ab
37
bugfix-fix-not-verifying-grub-cfg-when-loading-it.patch
Normal file
37
bugfix-fix-not-verifying-grub-cfg-when-loading-it.patch
Normal file
@ -0,0 +1,37 @@
|
||||
From b5793c27c88daef4383f002dd0c340ce9ae2ed17 Mon Sep 17 00:00:00 2001
|
||||
From: Qiumiao Zhang <zhangqiumiao1@huawei.com>
|
||||
Date: Tue, 24 Dec 2024 02:37:58 +0000
|
||||
Subject: [PATCH] fix not verifying grub.cfg when loading it
|
||||
|
||||
Fixes: c8b6446348a4 ("skip verification when not loading grub.cfg")
|
||||
|
||||
Signed-off-by: Qiumiao Zhang <zhangqiumiao1@huawei.com>
|
||||
---
|
||||
grub-core/normal/main.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/grub-core/normal/main.c b/grub-core/normal/main.c
|
||||
index edbea53..d7a6b79 100644
|
||||
--- a/grub-core/normal/main.c
|
||||
+++ b/grub-core/normal/main.c
|
||||
@@ -133,7 +133,7 @@ read_config_file (const char *config)
|
||||
}
|
||||
|
||||
/* Try to open the config file. */
|
||||
- rawfile = grub_file_open (config, GRUB_FILE_TYPE_CONFIG);
|
||||
+ rawfile = grub_file_open (config, GRUB_FILE_TYPE_SKIP_SIGNATURE);
|
||||
if (! rawfile)
|
||||
return 0;
|
||||
|
||||
@@ -369,7 +369,7 @@ grub_try_normal_prefix (const char *prefix)
|
||||
if (config)
|
||||
{
|
||||
grub_file_t file;
|
||||
- file = grub_file_open (config, GRUB_FILE_TYPE_SKIP_SIGNATURE);
|
||||
+ file = grub_file_open (config, GRUB_FILE_TYPE_CONFIG);
|
||||
if (file)
|
||||
{
|
||||
grub_file_close (file);
|
||||
--
|
||||
2.33.0
|
||||
|
||||
@ -356,3 +356,4 @@ Patch0356: backport-osdep-Introduce-include-grub-osdep-major-h-and-use-it.patch
|
||||
Patch0357: backport-osdep-linux-hostdisk-Use-stat-instead-of-udevadm.patch
|
||||
Patch0358: backport-commands-legacycfg-Avoid-closing-file-twice.patch
|
||||
Patch0359: backport-disk-lvm-GRUB-fails-to-detect-LVM-volumes-due-to-an-.patch
|
||||
Patch0360: bugfix-fix-not-verifying-grub-cfg-when-loading-it.patch
|
||||
|
||||
@ -14,7 +14,7 @@
|
||||
Name: grub2
|
||||
Epoch: 1
|
||||
Version: 2.06
|
||||
Release: 49
|
||||
Release: 50
|
||||
Summary: Bootloader with support for Linux, Multiboot and more
|
||||
License: GPLv3+
|
||||
URL: http://www.gnu.org/software/grub/
|
||||
@ -453,6 +453,12 @@ fi
|
||||
%{_datadir}/man/man*
|
||||
|
||||
%changelog
|
||||
* Tue Dec 24 2024 zhangqiumiao <zhangqiumiao1@huawei.com> - 1:2.06-50
|
||||
- Type:bugfix
|
||||
- CVE:NA
|
||||
- SUG:NA
|
||||
- DESC:fix not verifying grub.cfg when loading it
|
||||
|
||||
* Sat Dec 21 2024 zhangqiumiao <zhangqiumiao1@huawei.com> - 1:2.06-49
|
||||
- Type:bugfix
|
||||
- CVE:NA
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user