[PATCH] elf: Don't read beyond .eh_frame section end

Alan Modra amodra@gmail.com
Tue Sep 30 23:25:10 GMT 2025


On Wed, Oct 01, 2025 at 08:15:52AM +0930, Alan Modra wrote:
> On Tue, Sep 30, 2025 at 10:34:08AM +0800, H.J. Lu wrote:
> > PR ld/33500
> > * elf-eh-frame.c (_bfd_elf_parse_eh_frame): Don't read beyond
> > the .eh_frame section end.
> 
> OK.

Actually, I think you should be using
	  REQUIRE (buf + 1 < end);
since buf[1] is accessed just below.

-- 
Alan Modra


More information about the Binutils mailing list