lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 5 Mar 2019 13:59:03 +1100 (AEDT)
From:   Finn Thain <fthain@...egraphics.com.au>
To:     Geert Uytterhoeven <geert@...ux-m68k.org>
cc:     kbuild test robot <lkp@...el.com>, kbuild-all@...org,
        linux-m68k <linux-m68k@...ts.linux-m68k.org>,
        Arnd Bergmann <arnd@...db.de>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [m68k:master 1174/1174] arch/m68k/include/asm/string.h:72:25:
 warning: '__builtin_memcpy' forming offset 8 is out of the bounds [0, 7]

On Tue, 5 Mar 2019, Finn Thain wrote:

> 
> Looks bogus to me.
> 
> If you change memcpy to __builtin_memcpy, then we avoid the macro and the 
> warning changes to,
> 
> ./include/linux/string.h:456:3: warning: '__builtin_memcpy' forming offset [7, 8] is out of the bounds [0, 6] [-Warray-bounds]
>    __builtin_memcpy(dest, src, dest_len);
> 
> The compiler has nothing to complain about here. dest is known to be 
> id->fr and dest_len is known to be sizeof(id->fr).
> 
> The error message indicates that gcc has applied the bounds [0, 6] to dest 
> when in fact those are the bounds for src.
> 

My mistake. GCC is right, it seems memcpy will read past the end of 
"5.0.0+".

-- 

Powered by blists - more mailing lists