On Fri, Feb 21, 2025 at 10:01:11AM +0100, Christian Hesse wrote: > Michael Chang via Grub-devel <grub-devel@gnu.org> on Fri, 2025/02/21 15:55: > > On Thu, Feb 20, 2025 at 12:27:12PM +0100, Tobias Powalowski via Grub-devel > > wrote: > > > It failed for my co-maintainer in 2 cases: > > > > > > - loopback device seems to be broken > > > > Is the loopback file placed on an ext2/3/4 file system? > > It is... > > > If so, it might > > be affected by '7e2f750f0a fs/ext2: Fix out-of-bounds read for inline > > extents'. Please test if this new patch helps. > > > > https://lists.gnu.org/archive/html/grub-devel/2025-02/msg00115.html > > ... and that patch fixes the loopback functionality for me. > > Just for reference... Without that patch the files were read with their > correct size, but contained just null bytes: > > grub> loopback loop archlinux.iso > grub> cat (loop)/arch/version > <0><0><0><0><0><0><0><0><0><0><0><0><0><0><0><0><0> > grub>
Yes. This happens because the loopback file is fragmented and its extent mapping cannot be fully stored in the inode's inline area. Consequently, the filesystem promotes the extent tree to use an external block. The previous patch mistakenly processed external extents using the inline layout assumptions, which led to reading too few entries from the external block. > > So one fixed, thanks! Thanks for your testing. Michael > -- > main(a){char*c=/* Schoene Gruesse */"B?IJj;MEH" > "CX:;",b;for(a/* Best regards my address: */=0;b=c[a++];) > putchar(b-1/(/* Chris cc -ox -xc - && ./x */b/42*2-3)*42);} _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel