grub2/grub2-menu-unrestricted.patch
Michael Chang cf7b25968b - Fix missng menu entry "Start bootloader from a read-only snapshot" by
ensuring grub2-snapper-plugin is installed when both snapper and grub2-common
  are installed (bsc#1231271) 

- Fix OOM error in loading loopback file (bsc#1230840)
  * 0001-tpm-Skip-loopback-image-measurement.patch

- Fix UEFI PXE boot failure on tagged VLAN network (bsc#1230263)
  * 0001-efinet-Skip-virtual-VLAN-devices-during-card-enumera.patch

- Fix grub screen is filled with artifects from earlier post menu (bsc#1224465)
  * grub2-SUSE-Add-the-t-hotkey.patch
  * 0001-fix-grub-screen-filled-with-post-screen-artifects.patch

OBS-URL: https://build.opensuse.org/package/show/Base:System/grub2?expand=0&rev=516
2024-10-04 09:29:44 +00:00

22 lines
516 B
Diff

--- a/grub-core/normal/menu.c
+++ b/grub-core/normal/menu.c
@@ -212,7 +212,17 @@
grub_size_t sz = 0;
if (entry->restricted)
- err = grub_auth_check_authentication (entry->users);
+ {
+ int auth_check = 1;
+ if (entry->users && entry->users[0] == 0)
+ {
+ const char *unr = grub_env_get ("unrestricted_menu");
+ if (unr && (unr[0] == '1' || unr[0] == 'y'))
+ auth_check = 0;
+ }
+ if (auth_check)
+ err = grub_auth_check_authentication (entry->users);
+ }
if (err)
{