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]
Date:	Tue, 26 Apr 2011 12:44:58 -0400
From:	Stephen Wilson <wilsons@...rt.ca>
To:	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>
Cc:	Hugh Dickins <hughd@...gle.com>, bookjovi@...il.com,
	Andrew Morton <akpm@...ux-foundation.org>,
	Al Viro <viro@...iv.linux.org.uk>,
	David Rientjes <rientjes@...gle.com>,
	Stephen Wilson <wilsons@...rt.ca>,
	open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] proc: fix pagemap_read() error case (was Re: [PATCH]
	proc: put check_mem_permission before __get_free_page in mem_read)

On Tue, Apr 26, 2011 at 02:50:16PM +0900, KOSAKI Motohiro wrote:
> I've finished audit other /proc allocation callsite. If my understand
> is correct, only pagemap_read() has the same issue.

I think there is one additional location that might be worth looking at.
We have a kmalloc(struct numa_maps) happening in show_numa_map() (see
mempolicy.c).  In this case there is an allocation/free cycle happening
for each vma as we generate the seq_file.

Unfortunately a fix might require a little work.  Initial thinking
suggests that we perform a single allocation at numa_maps_open() time.
However, there is an odd layering/dependency issue between mempolicy.c
and task_mmu.c.  A "simple clean fix" does not seem obvious to me.

I am very tempted to suggest we move the proc related stuff out of
mempolicy.c.  However, see 1a75a6c8.

Thoughts?  I can certainly look into this some more if needed.

-- 
steve

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ