lkml.org 
[lkml]   [2011]   [Nov]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 3/3] security: Yama: add ptrace relationship tracking interface
Hi Kees,

Thank you for working on this! We'll use Yama in Openwall too :-)

On Wed, Oct 26, 2011 at 16:49 -0700, Kees Cook wrote:
> + if (mode == PTRACE_MODE_ATTACH &&
> + ptrace_scope &&
> + !capable(CAP_SYS_PTRACE) &&
> + !task_is_descendant(current, child) &&
> + !ptracer_exception_found(current, child))
> + rc = -EPERM;

capable() is better to put after all other tests as a failed capable()
might emit a false positive warning into logs or something.

Thanks,

--
Vasiliy


\
 
 \ /
  Last update: 2011-11-19 17:35    [W:0.172 / U:25.052 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site