Kees Cook 5883f57ca0 proc: protect mm start_code/end_code in /proc/pid/stat
While mm->start_stack was protected from cross-uid viewing (commit
f83ce3e6b02d5 ("proc: avoid information leaks to non-privileged
processes")), the start_code and end_code values were not.  This would
allow the text location of a PIE binary to leak, defeating ASLR.

Note that the value "1" is used instead of "0" for a protected value since
"ps", "killall", and likely other readers of /proc/pid/stat, take
start_code of "0" to mean a kernel thread and will misbehave.  Thanks to
Brad Spengler for pointing this out.

Addresses CVE-2011-0726

Signed-off-by: Kees Cook <kees.cook@canonical.com>
Cc: <stable@kernel.org>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Eugene Teo <eugeneteo@kernel.sg>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Brad Spengler <spender@grsecurity.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-03-23 19:46:37 -07:00
..
2011-03-17 14:02:57 +01:00
2011-02-25 11:12:37 -08:00
2011-02-21 22:31:47 +00:00
2011-03-10 13:22:34 -06:00
2011-01-07 17:50:26 +11:00
2011-03-03 01:28:17 -05:00
2011-03-23 19:46:17 -07:00
2011-01-07 17:50:26 +11:00
2011-01-14 09:23:36 -08:00
2011-01-12 20:03:42 -05:00
2011-03-02 22:27:36 +01:00
2011-01-07 17:50:26 +11:00
2011-03-17 14:02:57 +01:00
2011-03-21 00:45:50 -04:00
2011-03-23 19:46:18 -07:00
2011-03-01 15:47:58 +01:00
2011-03-17 14:02:57 +01:00
2011-03-23 19:46:17 -07:00
2011-01-07 17:50:26 +11:00
2011-01-07 17:50:26 +11:00
2010-10-29 04:16:31 -04:00
2011-01-07 17:50:26 +11:00
2011-03-03 01:28:16 -05:00
2011-03-23 19:46:19 -07:00
2011-03-23 19:46:19 -07:00
2010-10-29 04:16:28 -04:00
2011-03-21 00:16:09 -04:00
2011-03-15 02:21:44 -04:00
2011-01-07 17:50:27 +11:00
2011-03-21 00:16:08 -04:00
2011-01-13 17:32:32 -08:00
2011-03-21 01:10:41 -04:00
2011-01-07 17:50:33 +11:00
2011-03-14 09:15:28 -04:00