diff options
author | Oleg Nesterov <oleg@redhat.com> | 2015-11-07 03:30:06 +0300 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-11-07 04:50:42 +0300 |
commit | 54708d2858e79a2bdda10bf8a20c80eb96c20613 (patch) | |
tree | 4228afc090f3a84482ec6a039b06e3769c0ee1a1 /include/linux/compiler-gcc.h | |
parent | 3a49f3d2a10dfb27411d321900197a3d6c52405b (diff) | |
download | linux-54708d2858e79a2bdda10bf8a20c80eb96c20613.tar.xz |
proc: actually make proc_fd_permission() thread-friendly
The commit 96d0df79f264 ("proc: make proc_fd_permission() thread-friendly")
fixed the access to /proc/self/fd from sub-threads, but introduced another
problem: a sub-thread can't access /proc/<tid>/fd/ or /proc/thread-self/fd
if generic_permission() fails.
Change proc_fd_permission() to check same_thread_group(pid_task(), current).
Fixes: 96d0df79f264 ("proc: make proc_fd_permission() thread-friendly")
Reported-by: "Jin, Yihua" <yihua.jin@intel.com>
Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/compiler-gcc.h')
0 files changed, 0 insertions, 0 deletions