On Fri, Feb 28, 2025 at 01:07:06PM +0000, B Horn wrote:
> On some NTFS volumes GRUB would enter an infinite loop when
> next_attribute() returned NULL, which can happen in normal cases when
> the end of the attribute list is reached.
> This would trigger a NULL deref, but as the null page is mapped on the
> majority of firmware, an infinite loop would occur as the while loop
> didn't make any progress.
> 
> Fixing this by verifying the value of at->attr_cur on the next iteration
> of the loop, after it has been set to the result of next_attribute().
> Also removing the redundant check against mft_end as the
> next_attribute() should handle that now.
> A pointer to the end of the buffer is stored in at->end, which is
> initialized the same way as mft_end was.
> 
> Fixes: https://savannah.gnu.org/bugs/index.php?66855
> 
> Reported-by: Andreas Klauer <andreas.kla...@metamorpher.de>
> Signed-off-by: B Horn <b...@horn.uk>

Thank you, it works fine here.

Regards
Andreas

_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/grub-devel

Reply via email to