[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20081205034402.GB1626@mail.local.tull.net>
Date: Fri, 5 Dec 2008 14:44:02 +1100
From: Nick Andrew <nick@...k-andrew.net>
To: Valdis.Kletnieks@...edu
Cc: Geoffrey McRae <geoff@...idhost.com>,
Peter Teoh <htmldeveloper@...il.com>,
Alan Cox <alan@...rguk.ukuu.org.uk>,
linux-kernel@...r.kernel.org
Subject: Re: New Security Features, Please Comment
On Thu, Dec 04, 2008 at 10:35:27PM -0500, Valdis.Kletnieks@...edu wrote:
> You're also overlooking the fact that the malicious code could do something
> like this:
>
> /* send the parent something that makes it *think* the request finished */
> printf("We're all done now\n");
> while (getpid()) msleep (1);
I think it's pretty basic that setgid/setuid needs to be done _before_
exec'ing untrusted code.
On the other hand, if a trusted process gets its uid changed _and_
expects this to happen then I suppose it can be secure. But if a
process's uid gets changed unexpectedly then nasty things already
pointed out by Alan and others can occur.
Nick.
--
PGP Key ID = 0x418487E7 http://www.nick-andrew.net/
PGP Key fingerprint = B3ED 6894 8E49 1770 C24A 67E3 6266 6EB9 4184 87E7
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists