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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 12 Oct 2022 09:11:44 +1300
From:   Paulo Miguel Almeida <paulo.miguel.almeida.rodenas@...il.com>
To:     Kees Cook <keescook@...omium.org>
Cc:     Christine Caulfield <ccaulfie@...hat.com>,
        David Teigland <teigland@...hat.com>, cluster-devel@...hat.com,
        linux-kernel@...r.kernel.org, linux-hardening@...r.kernel.org
Subject: Re: [PATCH v4] [next] dlm: replace one-element array with fixed size
 array

On Tue, Oct 11, 2022 at 01:06:32PM -0700, Kees Cook wrote:
> On Wed, Oct 12, 2022 at 09:04:15AM +1300, Paulo Miguel Almeida wrote:
> >  	error = -ENOMEM;
> >  
> > -	ls = kzalloc(sizeof(struct dlm_ls) + namelen, GFP_NOFS);
> > +	ls = kzalloc(sizeof(struct dlm_ls), GFP_NOFS);
>                      ^^^^^^^^^^^^^^^^^^^^
> I think you forgot the suggestion Gustavo had here. :) Preferred style would
> be:
> 	sizeof(*ls)
> 
Ooops, I hadn't seen that one =O 

Alright, v5 in the making

Paulo A.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ