[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #26789] Multiboot Loader Fixes (Patch attached)

From: Owen Shepherd
Subject: [bug #26789] Multiboot Loader Fixes (Patch attached)
Date: Fri, 12 Jun 2009 13:38:31 +0000
User-agent: Opera/9.80 (X11; Linux x86_64; U; en-GB) Presto/2.2.15 Version/10.00


                 Summary: Multiboot Loader Fixes (Patch attached)
                 Project: GNU GRUB
            Submitted by: tcowens
            Submitted on: Fri 12 Jun 2009 13:38:29 GMT
                Category: Booting
                Severity: Major
                Priority: 5 - Normal
              Item Group: Software Error
                  Status: None
                 Privacy: Public
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: HEAD
         Reproducibility: Every Time
         Planned Release: 



Grub2 currently does the following when attempting to load a Multiboot file:

Read 8192 bytes, and check for a Multiboot 1 header
Read another 8192 bytes, and check for a Multiboot 2 header.

There is a bug here: The multiboot 2 header is read from the wrong location.

There is also, in my opinion, a deficiency here in addition: It checks for a
Multiboot 1 header first.

The attached patch does two things:
Firstly, it reads the first 8192 bytes into a buffer shared between both
header checks, fixing the bug.
Secondly, it checks for a Multiboot 2 header first. This allows kernels to
take advantage of Multiboot 2 if available, and fall back to Multiboot 1 if

The patch was generated against HEAD from my Git mirror of trunk/grub2/. If
it needs generating another way, please let me know (Though it's so trivial it
should be easy to apply by hand).

It touches only loader/multiboot_loader.c


File Attachments:

Date: Fri 12 Jun 2009 13:38:29 GMT  Name: multiboot_fix.diff  Size: 2kB   By:
Apply against head, trunk/grub2/


Reply to this item at:


  Message sent via/by Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]