Bug 2228016 - grubby sets --unrestricted for all BLS entries, rendering password protection ineffective
Summary: grubby sets --unrestricted for all BLS entries, rendering password protection...
Keywords:
Status: NEW
Alias: None
Product: Fedora
Classification: Fedora
Component: grubby
Version: 38
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Peter Jones
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-08-01 07:02 UTC by James
Modified: 2023-08-01 07:03 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: ---
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description James 2023-08-01 07:02:38 UTC
Description of problem:
According to grub 2.06 documentation, "Superusers are permitted to use the GRUB command line, edit menu entries, and execute any menu entry." Currently bash script grubby sets "grub_arg --unrestricted" for all BLS entries in /boot/loader/entries. This allows any menu entry to be executed without requiring a password, even if a group of superusers would have been defined.

Version-Release number of selected component (if applicable):
grubby 8.40-69

How reproducible:
always

Steps to Reproduce:

The problem itself can be reproduced by verifying that entries in /boot/loader/entries have "grub_arg --unrestricted:
1. grep --files-with-matches "grub_arg --unrestricted" /boot/loader/entries/*.conf

The effect of "--unrestricted" in password protection can be reproduced as follows:
1. password-protect grub; this can be a bit tricky, as grub2-set-password also has a bug affecting UEFI systems: see https://bugzilla.redhat.com/show_bug.cgi?id=2227718
2. reboot
3. in grub menu, boot any non-default entry without being prompted for password

Actual results:
after enabling password protection (authentication), any non-default grub entry can be executed without password

Expected results:
after enabling password protection (authentication), execution of non-default grub entries should be password protected


Additional info:


Note You need to log in before you can comment on or make changes to this bug.