grub-devel
[Top][All Lists]
Advanced

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

Re: modules size in mkimage


From: Vladimir 'phcoder' Serbinenko
Subject: Re: modules size in mkimage
Date: Wed, 4 Nov 2015 12:29:43 +0100


Le 4 nov. 2015 12:26 PM, "Andrei Borzenkov" <address@hidden> a écrit :
>
> 04.11.2015 14:21, Vladimir 'phcoder' Serbinenko пишет:
>
>> Le 31 oct. 2015 8:02 AM, "Andrei Borzenkov" <address@hidden> a écrit :
>>>
>>>
>>> mkimage sets module size to aligned value; later it is used to actually
>>
>> process it which /may/ lead to inconsistency (as any comparison is against
>> stored aligned size, not actual module size).
>>>
>>>
>> Which inconsistency do you have in mind?
>
>
>   if (size < e->e_shoff + e->e_shentsize * e->e_shnum)
>     {
>       grub_error (GRUB_ERR_BAD_OS, "ELF sections outside core");
>
This is just to avoid accessing unallocated data. In this case the memory is allocated. So it's a minor issue. I'm more concerned with some module iterator breaking
>
>
>
>
> _______________________________________________
> Grub-devel mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/grub-devel


reply via email to

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