[Bug libelf/31225] Crash when using elf_memory() on a compressed section; fixed with s/ELF_C_READ/ELF_C_READ_MMAP/

mark at klomp dot org sourceware-bugzilla@sourceware.org
Thu Feb 1 14:39:52 GMT 2024


https://sourceware.org/bugzilla/show_bug.cgi?id=31225

Mark Wielaard <mark at klomp dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2024-02-01
             Status|UNCONFIRMED                 |ASSIGNED
           Assignee|unassigned at sourceware dot org   |mark at klomp dot org

--- Comment #3 from Mark Wielaard <mark at klomp dot org> ---
(In reply to Derek Bruening from comment #2)
> I had thought with the ELF_C_READ_MMAP support elfutils
> deliberately supported read-only mappings in general?

You are basically right. But I had to carefully read the code to make sure this
really was the case when the user used elf_memory. Which, as you also point
out, doesn't have any testcases. So I added one that checks various issues (and
that fails before your suggested change). Please take a look:

https://inbox.sourceware.org/elfutils-devel/20240201143858.930159-1-mark@klomp.org/

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Elfutils-devel mailing list