From: Al Viro Date: Wed, 2 Jan 2008 14:09:57 +0000 (+0000) Subject: restrict reading from /proc//maps to those who share ->mm or can ptrace pid X-Git-Tag: v2.6.24-rc7~16 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=831830b5a2b5d413407adf380ef62fe17d6fcbf2;p=pandora-kernel.git restrict reading from /proc//maps to those who share ->mm or can ptrace pid Contents of /proc/*/maps is sensitive and may become sensitive after open() (e.g. if target originally shares our ->mm and later does exec on suid-root binary). Check at read() (actually, ->start() of iterator) time that mm_struct we'd grabbed and locked is - still the ->mm of target - equal to reader's ->mm or the target is ptracable by reader. Signed-off-by: Al Viro Acked-by: Rik van Riel Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed