[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20181203103406.GF3095@unbuntlaptop>
Date:   Mon, 3 Dec 2018 13:34:06 +0300
From:   Dan Carpenter <dan.carpenter@...cle.com>
To:     Alexei Starovoitov <alexei.starovoitov@...il.com>,
        Roman Gushchin <guro@...com>
Cc:     Alexei Starovoitov <ast@...nel.org>,
        Daniel Borkmann <daniel@...earbox.net>,
        "David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
        kernel-janitors@...r.kernel.org, guro@...com
Subject: Re: [PATCH net] bpf: uninitialized variables in test code
I'm afraid Roman's patch doesn't fix the bug.
On Fri, Nov 30, 2018 at 02:58:03PM -0800, Alexei Starovoitov wrote:
> On Thu, Nov 29, 2018 at 01:27:03PM +0300, Dan Carpenter wrote:
> > Smatch complains that if bpf_test_run() fails with -ENOMEM at the
> > begining then the "duration" is uninitialized.  We then copy the
> > unintialized variables to the user inside the bpf_test_finish()
> > function.  The functions require CAP_SYS_ADMIN so it's not really an
> > information leak.
> > 
> > Fixes: 1cf1cae963c2 ("bpf: introduce BPF_PROG_TEST_RUN command")
> > Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
> 
> That is incorrect fixes tag.
Yeah.  You're right.  The Fixes tag is wrong.  I spent some time looking
at this too, because the code is old but the warning only just
appeared...  :/
Thanks for fixing this, Roman.
regards,
dan carpenter
Powered by blists - more mailing lists