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] [day] [month] [year] [list]
Message-ID: <20160520130732.GA12270@kp>
Date:	Fri, 20 May 2016 18:37:32 +0530
From:	Muhammad Falak R Wani <falakreyaz@...il.com>
To:	Heiko Carstens <heiko.carstens@...ibm.com>
Cc:	Martin Schwidefsky <schwidefsky@...ibm.com>,
	Jan Kara <jack@...e.cz>,
	"open list:S390" <linux-s390@...r.kernel.org>,
	open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ks390/keyboard: use memdup_user().

On Fri, May 20, 2016 at 03:03:25PM +0200, Heiko Carstens wrote:
> On Fri, May 20, 2016 at 05:52:16PM +0530, Muhammad Falak R Wani wrote:
> > Use memdup_user to duplicate a memory region from user-space to
> > kernel-space, instead of open coding using kmalloc & copy_from_user.
> > 
> > Signed-off-by: Muhammad Falak R Wani <falakreyaz@...il.com>
> > +		p = memdup_user(u_kbs->kb_string, len);
> > +		if (IS_ERR(p))
> > +			return PTR_ERR(p);
> >  		/*
> >  		 * Make sure the string is terminated by 0. User could have
> >  		 * modified it between us running strnlen_user() and copying it.
> 
> Hi Muhammad, thanks for this patch. However could you change this to use
> memdup_user_nul() instead, so we can get rid of even more code?
> 
Should I send V2 with the suggested changes ?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ