|
Message-ID: <1310759683.30257.123.camel@moss-pluto> Date: Fri, 15 Jul 2011 15:54:43 -0400 From: Stephen Smalley <sds@...ho.nsa.gov> To: Vasiliy Kulikov <segoon@...nwall.com> Cc: NeilBrown <neilb@...e.de>, kernel-hardening@...ts.openwall.com, Solar Designer <solar@...nwall.com>, James Morris <jmorris@...ei.org>, Linus Torvalds <torvalds@...ux-foundation.org>, linux-kernel@...r.kernel.org, Greg Kroah-Hartman <gregkh@...e.de>, Andrew Morton <akpm@...ux-foundation.org>, "David S. Miller" <davem@...emloft.net>, Jiri Slaby <jslaby@...e.cz>, Alexander Viro <viro@...iv.linux.org.uk>, linux-fsdevel@...r.kernel.org, KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>, Eric Paris <eparis@...hat.com>, Willy Tarreau <w@....eu>, Sebastian Krahmer <krahmer@...e.de> Subject: Re: Re: [PATCH] move RLIMIT_NPROC check from set_user() to do_execve_common() On Fri, 2011-07-15 at 19:26 +0400, Vasiliy Kulikov wrote: > Hi Stephen, > > On Fri, Jul 15, 2011 at 09:58 -0400, Stephen Smalley wrote: > > Does this have implications for Android's zygote model? There you have > > a long running uid 0 / all caps process (the zygote), which forks itself > > upon receiving a request to spawn an app and then calls > > > setgroups(); > > setrlimit(); setgid(); setuid(); > > Is RLIMIT_NPROC forced in your model and setuid() is expected to fail > because of NPROC exceeding? If no, then it is not touched at all. I don't know what their intent is. But it is an example of a case where moving the enforcement from setuid() to a subsequent execve() causes the check to never get applied. As to whether or not they care, I don't know. An app that calls fork() repeatedly will still be stopped, but an app that repeatedly connects to the zygote and asks to spawn another instance of itself would be unlimited. OTOH, the current RLIMIT_NPROC check and lack of setuid() error checking has been a repeated issue for Android. -- Stephen Smalley National Security Agency
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.