lkml.org 
[lkml]   [2010]   [Jun]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] futex: futex_find_get_task make credentials check conditional
On Tue 29-06-10 09:41:02, Linus Torvalds wrote:
> On Tue, Jun 29, 2010 at 1:42 AM, Michal Hocko <mhocko@suse.cz> wrote:
> >
> > futex_find_get_task is currently used (through lookup_pi_state) from two
> > contexts, futex_requeue and futex_lock_pi_atomic. While credentials check
> > makes sense in the first code path, the second one is more problematic
> > because this check requires that the PI lock holder (pid parameter) has
> > the same uid and euid as the process's euid which is trying to lock the
> > same futex (current).
>
> So exactly why does it make sense to check the credentials in the
> first code path then?

I though that requeue needs this for security reasons (don't let requeue
process for other user), but when I thought about that again you are
right and the only what matters should be accessibility of the shared
memory.


--
Michal Hocko
L3 team
SUSE LINUX s.r.o.
Lihovarska 1060/12
190 00 Praha 9
Czech Republic


\
 
 \ /
  Last update: 2010-06-30 09:03    [W:0.017 / U:0.072 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site