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: <CAHp75VdH4=fnygn-a3acrbjMAVkGb9qkSSvDoTkMUYfUWV3XYw@mail.gmail.com>
Date:   Fri, 9 Aug 2019 13:51:23 +0300
From:   Andy Shevchenko <andy.shevchenko@...il.com>
To:     Jia He <justin.he@....com>
Cc:     Petr Mladek <pmladek@...e.com>,
        Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        Sergey Senozhatsky <sergey.senozhatsky@...il.com>,
        Geert Uytterhoeven <geert+renesas@...der.be>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Thomas Gleixner <tglx@...utronix.de>,
        "Steven Rostedt (VMware)" <rostedt@...dmis.org>,
        Kees Cook <keescook@...omium.org>,
        Shuah Khan <shuah@...nel.org>,
        "Tobin C. Harding" <tobin@...nel.org>
Subject: Re: [PATCH 2/2] lib/test_printf: add test of null/invalid pointer
 dereference for dentry

On Fri, Aug 9, 2019 at 4:28 AM Jia He <justin.he@....com> wrote:
>
> This add some additional test cases of null/invalid pointer dereference
> for dentry and file (%pd and %pD)
>

Reviewed-by: Andy Shevchenko <andy.shevchenko@...il.com>

> Signed-off-by: Jia He <justin.he@....com>
> ---
>  lib/test_printf.c | 7 +++++++
>  1 file changed, 7 insertions(+)
>
> diff --git a/lib/test_printf.c b/lib/test_printf.c
> index 944eb50f3862..befedffeb476 100644
> --- a/lib/test_printf.c
> +++ b/lib/test_printf.c
> @@ -455,6 +455,13 @@ dentry(void)
>         test("foo", "%pd", &test_dentry[0]);
>         test("foo", "%pd2", &test_dentry[0]);
>
> +       /* test the null/invalid pointer case for dentry */
> +       test("(null)", "%pd", NULL);
> +       test("(efault)", "%pd", PTR_INVALID);
> +       /* test the null/invalid pointer case for file */
> +       test("(null)", "%pD", NULL);
> +       test("(efault)", "%pD", PTR_INVALID);
> +
>         test("romeo", "%pd", &test_dentry[3]);
>         test("alfa/romeo", "%pd2", &test_dentry[3]);
>         test("bravo/alfa/romeo", "%pd3", &test_dentry[3]);
> --
> 2.17.1
>


-- 
With Best Regards,
Andy Shevchenko

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ