Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 686054 - sys-boot/grub - grub-set-default and grub-reboot utilities should check for MENU_ENTRY parameter validity
Summary: sys-boot/grub - grub-set-default and grub-reboot utilities should check for M...
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Mike Gilbert
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-15 20:20 UTC by tot-to
Modified: 2019-05-17 12:28 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tot-to 2019-05-15 20:20:02 UTC
In case of a typo in the MENU_ENTRY parameter both grub-set-default and grub-reboot utilities exit with no error message and with successful exit status. After the reboot grub will try to load the first menu entry found in grub.cfg

I believe it it a very serious issue. In case if the first entry refers to an unbootable configuration on a remote server, it leads to total loose of the system until physical access is possible!

Steps to reproduce:

# grub-set-default blahblahblah && echo success

Expected results:

1) A error message
2) No change of the default menu entry upon reboot

Actual results:

1) Message 'success' is printed
2) The default menu entry in changed to the fist entry in grub.cfg upon reboot
Comment 1 Mike Gilbert gentoo-dev 2019-05-16 12:50:21 UTC
Report this upstream please.