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: <cb1dfcc1-e03e-4517-8f77-d08f10aa507c@linuxfoundation.org>
Date:   Mon, 9 Oct 2023 11:28:30 -0600
From:   Shuah Khan <skhan@...uxfoundation.org>
To:     Maciej Wieczor-Retman <maciej.wieczor-retman@...el.com>,
        akpm@...ux-foundation.org, christian@...lner.me,
        fenghua.yu@...el.com, keescook@...omium.org,
        ndesaulniers@...gle.com, coltonlewis@...gle.com,
        dmatlack@...gle.com, vipinsh@...gle.com, seanjc@...gle.com,
        brauner@...nel.org, pbonzini@...hat.com, shuah@...nel.org,
        hannes@...xchg.org, nphamcs@...il.com, reinette.chatre@...el.com
Cc:     ilpo.jarvinen@...ux.intel.com, linux-kselftest@...r.kernel.org,
        kvm@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-mm@...ck.org, Shuah Khan <skhan@...uxfoundation.org>
Subject: Re: [PATCH v4 0/8] Add printf attribute to kselftest functions

On 10/9/23 04:28, Maciej Wieczor-Retman wrote:
> Kselftest.h declares many variadic functions that can print some
> formatted message while also executing selftest logic. These
> declarations don't have any compiler mechanism to verify if passed
> arguments are valid in comparison with format specifiers used in
> printf() calls.
> 
> Attribute addition can make debugging easier, the code more consistent
> and prevent mismatched or missing variables.
> 
> Add a __printf() macro that validates types of variables passed to the
> format string. The macro is similarly used in other tools in the kernel.
> 
> Add __printf() attributes to function definitions inside kselftest.h that
> use printing.
> 
> Adding the __printf() macro exposes some mismatches in format strings
> across different selftests.
> 
> Fix the mismatched format specifiers in multiple tests.
> 
> Series is based on kselftests next branch.

How did you find these problems? I don't see any information
how these problems are found in the commit logs.

thanks,
-- Shuah

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ