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  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAK8P3a0k=XTmys46cvAd2k-TRPO0YLawFur4PzGA_scwr5mChQ@mail.gmail.com>
Date:   Tue, 13 Feb 2018 09:28:18 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     Willy Tarreau <w@....eu>
Cc:     Xiongfeng Wang <wangxiongfeng2@...wei.com>,
        Miguel Ojeda <miguel.ojeda.sandonis@...il.com>,
        Dan <dan.carpenter@...cle.com>,
        linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH V2] auxdisplay: use correct string length

On Tue, Feb 13, 2018 at 8:23 AM, Willy Tarreau <w@....eu> wrote:
> On Tue, Feb 13, 2018 at 09:19:21AM +0800, Xiongfeng Wang wrote:

>> This may suppress the gcc warning.
>
> In fact there are two big problems with gcc warnings :
>   - writing -Wno-something-unknown triggers an error on versions where
>     "something-unknown" isn't known, making it difficult to permanently
>     disable warnings (though in the kernel we handle this pretty fine)

We have the $(call cc-disable-warning) helper for this.

>   - warnings and diagnostics are conflated. Some warnings should only be
>     provided when the developer explicitly asks for suspicious stuff
>     (-Wsecurity, -Wsuspicious, etc) that would *not* be part of -Wall
>     since -Wall is usually used to report real warnings.

And this is what the W=1 and W=2 make options are for.

I originally asked Xiongfeng to look at some of the new gcc-8 warnings,
but must have miscommunicated at some point. I think we do want to
enable the new -Wstringop-overflow warnings by default and fix all
instances, including the false-positive ones. This is a useful warning
because it tells you when you actually write past a buffer, e.g. using
strcpy() with a source string that is longer than the destination.

For  -Wstringop-truncation, we can decide whether it should be W=1
or W=2, but I'd still make it possible for users and maintainers to
easily enable the warning when test building new code.

       Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ