[PATCH 2/2] cmdline: Fix two related integer underflows

2022-11-26 Thread Ryan Cohen
An unchecked decrement operation in cl_print() would cause a few integers to underflow. Where an output terminal's state is stored in cl_term, the values cl_term->ystart and cl_term->pos.y both underflow. This can be replicated with the following steps: 1. Get to the GRUB command line 2. Hold dow

[PATCH 0/2] Fix command line underflows and out-of-bounds write

2022-11-26 Thread Ryan Cohen
Hello everyone, I was messing around in the GRUB command line and I found two related integer underflows that occur on all platforms. I also found an out-of-bounds write that occurs only on i386 systems using the VGA text terminal. This out-of-bounds write is caused by one of the underflows, but I

[PATCH 1/2] vga_text: Prevent out-of-bounds writes to VGA text buffer

2022-11-26 Thread Ryan Cohen
Coordinates passed to screen_write_char() did not have any checks to ensure they are not out-of-bounds. This adds an if statement to prevent out-of-bounds writes to the VGA text buffer. Signed-off-by: Ryan Cohen --- grub-core/term/i386/pc/vga_text.c | 3 ++- 1 file changed, 2 insertions(+), 1 de

Re: Grub saved my Laptop, and made it usable. so i wanted to say thanks to everybody that worked on it.

2022-11-26 Thread James Wabi
Thank you Glenn ! Your answer was very helpful, the Cutmem i think worked, but the other one did not. *From a machine that had already usuntu installed and running, i knew that if the modifications worked, then if i run in terminal sudo Dmesg , i should see something like this:* *[0.00] r

Re: [PATCH v2 3/3] grub-mkrescue: Search by file UUID file rather than partition UUID for EFI boot

2022-11-26 Thread Pete Batard via Grub-devel
Just noticed that there's a typo in the title ("file UUID file") so please make sure to remove one of the "file" from the commit title if this patch does get validated for integration. Thanks, /Pete On 2022.11.25 17:22, Pete Batard wrote: The final piece needed to add UEFI file system trans