Re: [PATCH] ptrace: allow restriction of ptrace scope

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Kees Cook
Date: Wednesday, June 16, 2010 - 4:22 pm

Hi Alan,

On Thu, Jun 17, 2010 at 12:01:20AM +0100, Alan Cox wrote:

I'm not sure I follow this comment.  Sensitive things in /proc/$PID/* are
already protected by ptrace_may_access() with mode == ATTACH.


Certainly.  PTRACE can already be confined by SELinux and AppArmor.  I'm
looking for a general approach that doesn't require a system builder to
create MAC policies for unknown software.  I want to define a common core
behavior.


The LSM isn't stackable, so I can't put it there and choose this and
SELinux (for the case of software-without-a-policy).


I'm not clear how this is "a mess for anyone else" when it defaults to
the classic PTRACE behavior.  PTRACE itself is dangerous, so it's not
unreasonable to start inching away from it.


There is no infrastructure to selectively choose these general-purpose
features.  This is why there is a sysctl.  It's a global behavioral
change.

Since LSMs aren't arbitrarily stackable, asking me to move the code into
a new LSM isn't a particularly actionable suggestion.

-Kees

-- 
Kees Cook
Ubuntu Security Team
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] ptrace: allow restriction of ptrace scope, Kees Cook, (Wed Jun 16, 3:18 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Roland McGrath, (Wed Jun 16, 4:10 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Kees Cook, (Wed Jun 16, 4:22 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Roland McGrath, (Wed Jun 16, 5:11 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Eric W. Biederman, (Thu Jun 17, 5:29 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, James Morris, (Thu Jun 17, 6:45 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Eric W. Biederman, (Thu Jun 17, 1:45 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Randy Dunlap, (Thu Jun 17, 2:06 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Serge E. Hallyn, (Thu Jun 17, 3:50 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, James Morris, (Thu Jun 17, 4:03 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Eric W. Biederman, (Thu Jun 17, 4:11 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Casey Schaufler, (Thu Jun 17, 8:10 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Theodore Tso, (Fri Jun 18, 3:54 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Serge E. Hallyn, (Fri Jun 18, 5:36 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Eric W. Biederman, (Fri Jun 18, 6:50 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Serge E. Hallyn, (Fri Jun 18, 7:29 am)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Tetsuo Handa, (Fri Jun 18, 7:15 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Casey Schaufler, (Fri Jun 18, 7:23 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Eric W. Biederman, (Fri Jun 18, 7:49 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Frank Ch. Eigler, (Fri Jun 18, 8:19 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, James Morris, (Sun Jun 20, 5:52 pm)
Re: [PATCH] ptrace: allow restriction of ptrace scope, Valdis.Kletnieks, (Sun Jun 20, 7:16 pm)