📄 00000008.htm
字号:
size N, with the MF bit on (data content is irrelevant). The second is the <BR>last fragment (MF == 0) with a positive offset < N and with a payload of < N. <BR> <BR> Every linux implementation I have been able to look at seems to have this <BR>problem (1.x - 2.x, including the development kernels). <BR> <BR> Oh, by the way, NT/95 appear to have the bug also. Try sending 10 - 15 of <BR>these fragment combos to an NT/95 machine. <BR> <BR> Special thanks to klepto for bringing the problem to my attention and <BR>writing the initial exploit. <BR> <BR> route|daemon9 <A HREF="mailto:route@infonexus.com">route@infonexus.com</A> <BR> <BR>------[Begin] -- Guby Linux ------------------------------------------------- <BR> <BR>/* <BR> * Copyright (c) 1997 route|daemon9 <<A HREF="mailto:route@infonexus.com>">route@infonexus.com></A> 11.3.97 <BR> * <BR> * Linux/NT/95 Overlap frag bug exploit <BR> * <BR> * Exploits the overlapping IP fragment bug present in all Linux kernels and <BR> * NT 4.0 / Windows 95 (others?) <BR> * <BR> * Based off of: flip.c by klepto <BR> * Compiles on: Linux, *BSD* <BR> * <BR> * gcc -O2 teardrop.c -o teardrop <BR> * OR <BR> * gcc -O2 teardrop.c -o teardrop -DSTRANGE_BSD_BYTE_ORDERING_THING <BR> */ <BR> <BR>/* <BR> * 此处删去很多字, 嘿嘿, 嘿嘿 <BR> */ <BR> <BR>/* EOF */ <BR> <BR>------[End] -- Guby Linux ---------------------------------------------------- <BR> <BR> And the patch: <BR> <BR>------[Begin] -- Helu Linux ------------------------------------------------- <BR> <BR>--- ip_fragment.c Mon Nov 10 14:58:38 1997 <BR>+++ ip_fragment.c.patched Mon Nov 10 19:18:52 1997 <BR>@@ -12,6 +12,7 @@ <BR> * Alan Cox : Split from ip.c , see ip_input.c for history. <BR> * Alan Cox : Handling oversized frames <BR> * Uriel Maimon : Accounting errors in two fringe cases. <BR>+ * route : IP fragment overlap bug <BR> */ <BR> <BR> #include <linux/types.h> <BR>@@ -578,6 +579,22 @@ <BR> frag_kfree_s(tmp, sizeof(struct ipfrag)); <BR> } <BR> } <BR>+ <BR>+ /* <BR>+ * Uh-oh. Some one's playing some park shenanigans on us. <BR>+ * IP fragoverlap-linux-go-b00m bug. <BR>+ * route 11.3.97 <BR>+ */ <BR>+ <BR>+ if (offset > end) <BR>+ { <BR>+ skb->sk = NULL; <BR>+ printk("IP: Invalid IP fragment (offset > end) found from %s\n", <BR>in_ntoa(iph->saddr)); <BR>+ kfree_skb(skb, FREE_READ); <BR>+ ip_statistics.IpReasmFails++; <BR>+ ip_free(qp); <BR>+ return NULL; <BR>+ } <BR> <BR> /* <BR> * Insert this fragment in the chain of fragments. <BR> <BR>------[End] -- Helu Linux ---------------------------------------------------- <BR> <BR>EOF <BR> <BR>-- <BR>※ 修改:·lenx 於 Nov 14 19:57:55 修改本文·[FROM: 162.105.118.33] <BR>※ 来源:·BBS 水木清华站 bbs.net.tsinghua.edu.cn·[FROM: 162.105.118.33] <BR><CENTER><H1>BBS水木清华站∶精华区</H1></CENTER></BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -