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: <20190523002923.GA14060@zhanggen-UX430UQ>
Date:   Thu, 23 May 2019 08:29:23 +0800
From:   Gen Zhang <blackgod016574@...il.com>
To:     Kees Cook <keescook@...omium.org>
Cc:     linux-kernel@...r.kernel.org
Subject: Re: [PATCH] consolemap: Fix a memory leaking bug in
 drivers/tty/vt/consolemap.c

On Wed, May 22, 2019 at 01:54:47PM -0700, Kees Cook wrote:
> On Wed, May 22, 2019 at 09:50:55AM +0800, Gen Zhang wrote:
> > On Tue, May 21, 2019 at 01:44:33PM -0700, Kees Cook wrote:
> > > This doesn't look safe to me: p->uni_pgdir[n] will still have a handle
> > > to the freed memory, won't it?
> > > 
> > Thanks for your reply, Kees!
> > I think you are right. Maybe we should do this:
> > 	kfree(p1);
> > 	p->uni_pgdir[n] = NULL;
> > Is this correct?
> 
> That's what I'm not sure about. I *think* so, from reading the code, but
> I'd love to have Greg (or someone more familiar with the code) to
> double-check this.
> 
> Otherwise, yeah, this looks right. Please send a v2 and we can debate
> the correctness there, if it turns out to be wrong. :)
> 
> -- 
> Kees Cook
Thanks for your suggestions, Kees.
I follow your guidance and work on resubmitting a patch.
Thanks
Gen

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ