]> git.baikalelectronics.ru Git - kernel.git/commit
deal with races in /proc/*/{syscall,stack,personality}
authorAl Viro <viro@zeniv.linux.org.uk>
Wed, 23 Mar 2011 19:52:50 +0000 (15:52 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Wed, 23 Mar 2011 21:01:18 +0000 (17:01 -0400)
commita8f0a0d8c5c0cb961ebe70806a29d77aa8615213
treec40217e028ae937da7ad94e249e2247191ffcc8f
parentdcb0cfe90a9d902a07b533834f60a74187452930
deal with races in /proc/*/{syscall,stack,personality}

All of those are rw-r--r-- and all are broken for suid - if you open
a file before the target does suid-root exec, you'll be still able
to access it.  For personality it's not a big deal, but for syscall
and stack it's a real problem.

Fix: check that task is tracable for you at the time of read().

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/proc/base.c