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] [thread-next>] [day] [month] [year] [list]
Message-ID: <1b3ba24e-0180-8472-199c-07aa56451e4a@rasmusvillemoes.dk>
Date:   Mon, 29 Oct 2018 11:20:20 +0100
From:   Rasmus Villemoes <linux@...musvillemoes.dk>
To:     Miguel Ojeda <miguel.ojeda.sandonis@...il.com>
Cc:     Kees Cook <keescook@...omium.org>,
        Andrew Morton <akpm@...ux-foundation.org>,
        linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [RFC PATCH 1/7] compiler_attributes.h: add
 __attribute__((format_arg)) shorthand

On 2018-10-27 14:06, Miguel Ojeda wrote:
> Hi Rasmus,
> 
> On Sat, Oct 27, 2018 at 1:24 AM Rasmus Villemoes
> <linux@...musvillemoes.dk> wrote:
>>
>> +/*
>> + * Optional
> 
> I did quick check and gcc >= 4.1, clang >= 3.0, icc >= 13 compilers
> seem to support it (or at least recognize it, even if they just ignore
> it), so we do not need to make it optional, no? Did I miss some case?

No idea. I think I didn't really know what was meant by
required/optional. E.g. something like __aligned must be supported and
honoured for correctness, while format_arg is just about getting some
diagnostics, and assume_aligned just allows for certain optimizations,
so it doesn't really matter whether every single compiler understands
them. It does seem that both icc and clang understand format_arg and
issues warnings when the template doesn't match the varargs, so in that
sense we can make it "required", though it seems a little backwards to
define required in terms of what the current range of compilers support.

Rasmus

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ