https://sourceware.org/bugzilla/show_bug.cgi?id=22829
--- Comment #7 from NGG <ngg at tresorit dot com> --- Thank you for the quick response and patch proposal. Sorry for overreacting. I assigned it to critical due to its possible security implications and because of the wide range of products it might affect. I should have either written this at my initial description or leave it at normal and let you decide its severity. Your patch seems to work in my case, I've tried it with a few examples with all of ld.bfd, ld.gold, ld.lld. Although it is strange that for example on my sample input the Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align GNU_RELRO 0x003000 0x0000000000203000 0x0000000000203000 0x0001a0 0x001000 R 0x1 becomes (after stripping) GNU_RELRO 0x003000 0x0000000000203000 0x0000000000203000 0x001000 0x001000 R 0x1 The whole file is smaller than 0x4000 so p_filesz cannot be correct. It's working because the glibc dynamic linker only checks p_vaddr, p_memsz (https://sourceware.org/git/?p=glibc.git;a=blob;f=elf/dl-load.c;hb=7bb087bd7bfe3616c4c0974a3f7352b593353ea5#l1095) -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org https://lists.gnu.org/mailman/listinfo/bug-binutils