Re: [PATCH 5/6] proc: use task_access_lock() instead of ptrace_may_access()

Cong Wang
2012-04-12T13:22:40Z

On 04/11/2012 01:59 PM, Cong Wang wrote:
> There are several places in fs/proc/base.c still use ptrace_may_access()
> directly to check the permission, actually this just gets a snapshot of
> the permission, nothing prevents the target task from raising the priviledges
> itself, it is better to use task_access_lock() for these places, to hold
> the priviledges.
>
Hi, Andrew,

Please drop this patch, it introduces a deadlock when execve() a
/proc/<pid>/exec file, and it is not a big improvement nor fixes any
bugs, so let's just drop this one.

Thanks!