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

--- Comment #5 from Sourceware Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Alan Modra <amo...@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=a5858e81363051a818ea163d52f62d8251097d11

commit a5858e81363051a818ea163d52f62d8251097d11
Author: Alan Modra <amo...@gmail.com>
Date:   Sun Aug 17 21:34:17 2025 +0930

    Sanity check windows resource version len

    oss-fuzz generated a total length field of 32, when the header was 40
    bytes.  Subtracting gave -8ul for the remaining length..

    I think we should be sanity checking the total length given in the
    header against the remaining buffer length and the size of the header
    each time get_version_header is called.

    Possibly vallen should be sanity checked inside get_version_header
    too, but I'll leave that to someone else.

            PR 27686
            * resbin.c (bin_to_res_version): Correct error message arg.
            Move len vs. buffer length sanity check..
            (get_version_header): ..to here.  Also sanity check len
            against off.

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

Reply via email to