diff --git a/add-tpcm-support-with-ipmi-channel.patch b/add-tpcm-support-with-ipmi-channel.patch index 8f06653..952b041 100644 --- a/add-tpcm-support-with-ipmi-channel.patch +++ b/add-tpcm-support-with-ipmi-channel.patch @@ -1,5 +1,5 @@ -From ae2d15e3f061197fce2a9106c8cfb2ab037aa171 Mon Sep 17 00:00:00 2001 -From: t.feng +From 9a6cb051b5f33f1138c1457dbb5b7a726297ee06 Mon Sep 17 00:00:00 2001 +From: "t.feng" Date: Tue, 28 Feb 2023 16:25:30 +0800 Subject: [PATCH] add tpcm support with ipmi channel @@ -16,9 +16,9 @@ Signed-off-by: "t.feng" Signed-off-by: zhangqiumiao --- grub-core/Makefile.core.def | 6 + - grub-core/commands/efi/tpcm.c | 464 ++++++++++++++++++++++++++++++++++ + grub-core/commands/efi/tpcm.c | 458 ++++++++++++++++++++++++++++++++++ include/grub/efi/tpcm.h | 235 +++++++++++++++++ - 3 files changed, 705 insertions(+) + 3 files changed, 699 insertions(+) create mode 100644 grub-core/commands/efi/tpcm.c create mode 100644 include/grub/efi/tpcm.h @@ -41,10 +41,10 @@ index b26774b..935195f 100644 common = commands/tr.c; diff --git a/grub-core/commands/efi/tpcm.c b/grub-core/commands/efi/tpcm.c new file mode 100644 -index 0000000..42a05eb +index 0000000..0803b9b --- /dev/null +++ b/grub-core/commands/efi/tpcm.c -@@ -0,0 +1,464 @@ +@@ -0,0 +1,458 @@ +#include +#include +#include @@ -55,7 +55,6 @@ index 0000000..42a05eb +#include +#include +#include -+#include + +GRUB_MOD_LICENSE ("GPLv3+"); + @@ -462,15 +461,10 @@ index 0000000..42a05eb +static grub_err_t +tpcm_ipmi_measure (unsigned char *buf, grub_size_t size, const char *description) +{ -+ grub_dprintf("tpcm", "hash file: %s\n", description); + if (tpcm_ipmi_get_switch()) + { -+ const char *skip_tpcm; -+ skip_tpcm = grub_env_get ("skip_tpcm"); -+ if (skip_tpcm && (skip_tpcm[0] == '1')) -+ grub_dprintf ("tpcm", "tpcm: skip tpcm measure\n"); -+ else -+ return grub_tpcm_log_event(buf, size, description); ++ grub_dprintf("tpcm", "hash file: %s\n", description); ++ return grub_tpcm_log_event(buf, size, description); + } + + return GRUB_ERR_NONE; @@ -751,5 +745,5 @@ index 0000000..eea1387 + +#endif -- -2.23.0 +2.27.0 diff --git a/grub2.spec b/grub2.spec index 14ed5e8..9fd697f 100644 --- a/grub2.spec +++ b/grub2.spec @@ -8,7 +8,7 @@ Name: grub2 Epoch: 1 Version: 2.04 -Release: 29 +Release: 30 Summary: Bootloader with support for Linux, Multiboot and more License: GPLv3+ URL: http://www.gnu.org/software/grub/ @@ -442,6 +442,12 @@ rm -r /boot/grub2.tmp/ || : %{_datadir}/man/man* %changelog +* Tue Feb 28 2023 fengtao - 1:2.04-30 +- Type:feature +- CVE:NA +- SUG:NA +- DESC:drop the environment variable of skip_tpcm + * Tue Feb 28 2023 fengtao - 1:2.04-29 - Type:feature - CVE:NA