[PATCH v2] mips: dl-machine-reject-phdr: Get rid of alloca.
Joe Simmons-Talbott
josimmon@redhat.com
Fri Jun 23 17:28:39 GMT 2023
On Fri, Jun 23, 2023 at 06:26:14PM +0200, Florian Weimer wrote:
> * Joe Simmons-Talbott via Libc-alpha:
>
> > Use a scratch_buffer rather than alloca to avoid potential stack
> > overflow.
>
> I think the code could read only the part of the program header that it
> actually needs. I don't see anything that iterates through the entire
> byte array.
>
> It was probably modeled on the old PT_NOTE handling code, which also
> used alloca, and that had to iterate through the data.
>
I've posted a v2 that hopefully addresses this. Thanks for reviewing.
Thanks,
Joe
More information about the Libc-alpha
mailing list