From c2a22f928c979a66c3769b923802c770420c3f7b Mon Sep 17 00:00:00 2001 From: Thore Sommer Date: Tue, 23 Jul 2024 12:32:41 +0200 Subject: [PATCH] sbat.c: add user facing message when SBAT self check fails This also increases the time until shutdown to 8 seconds. Signed-off-by: Thore Sommer --- shim.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/shim.c b/shim.c index 87202f7ff..9b079c3f9 100644 --- a/shim.c +++ b/shim.c @@ -1966,10 +1966,18 @@ efi_main (EFI_HANDLE passed_image_handle, EFI_SYSTEM_TABLE *passed_systab) die: console_print(L"Something has gone seriously wrong: %s: %r\n", msgs[msg], efi_status); + + /* + * Provide additional information when the SBAT self check fails + */ + if ( msg == SBAT_SELF_CHECK ) { + console_print(L"\nThe current shim has likely been revoked. " + "Please update to a newer shim version.\n"); + } #if defined(ENABLE_SHIM_DEVEL) devel_egress(COLD_RESET); #else - usleep(5000000); + usleep(8000000); RT->ResetSystem(EfiResetShutdown, EFI_SECURITY_VIOLATION, 0, NULL); #endif