Re: Reminder: $EDITOR with spaces?
From: Mark Benedetto King <bking_at_answerfriend.com>
Date: 2002-04-29 08:40:22 CEST
On Sun, Apr 28, 2002 at 11:28:56PM +0200, Marcus Comstedt wrote:
Historically, many vulnerabilities have resulted from insufficient
This will seem a little contrived, but it is an example:
Let's say an administrator wants to build s setuid-svn executable
mycommit foo
and will eventuall call, as uid=svn:
EDITOR="/path/to/editor foo" svn commit
Let's not try to understand *why* the administrator might
One might think that, presuming that the executable
execl("/bin/sh","sh","-c",$EDITOR,0);
So, let's say the user runs
mycommit "foo; cp /bin/sh /tmp/; chmod 4777 /tmp/sh"
You can see where this goes wrong.
So, that means before we call system, either we need
--ben
---------------------------------------------------------------------
|
This is an archived mail posted to the Subversion Dev mailing list.
This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.