Cual es la diferencia?
Esta sección te permite ver todos los mensajes escritos por este usuario. Ten en cuenta que sólo puedes ver los mensajes escritos en zonas a las que tienes acceso en este momento.
Mostrar Mensajes Menú
Private Sub Form_Load()
' Abre la conexión
Call IniciarConexion
' carga el Recorset con todos los datos
rs.Open "select * from Consulta1", cnn, adOpenStatic, adLockOptimistic
' llena el flexgrid
Call CargarFlex(flex)
Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=bd.mdb; Persist Security Info=False"
Adodc1.RecordSource = "select * from Consulta1"
Adodc1.Refresh
End Sub
Private Sub Text1_Change()
rs.Close
rs.Open "SELECT * FROM Inventario WHERE Barcode LIKE '" & Text1.Text & "%" & "'", cnn, adOpenStatic, adLockOptimistic
Set flex.DataSource = rs
End Sub
Option Explicit
Public Declare Sub InitCommonControls Lib "Comctl32" ()
Public flex As MSHFlexGrid
Public cnn As New ADODB.Connection
Public rs As New ADODB.Recordset
Sub CargarFlex(flex As MSHFlexGrid)
Set flex.DataSource = rs
With flex
.ColAlignmentFixed(0) = 1
.ColAlignment(0) = 1
.ColAlignmentFixed(5) = 8
.ColAlignment(5) = 8
End With
End Sub
Public Sub IniciarConexion()
With cnn
.CursorLocation = adUseClient
.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=bd.mdb; Persist Security Info=False"
End With
End Sub
Sub Desconectar()
On Local Error Resume Next
rs.Close
Set rs = Nothing
cnn.Close
Set cnn = Nothing
End Sub
Call ReGrid "SELECT * FROM Inventario WHERE Barcode LIKE '" & Text1.Text & "%" & "'" , flex
Private Sub txtSearch_Change()
sent = "SELECT * FROM stock WHERE Descripcion LIKE '" & txtSearch & "%" & "'"
Adodc1.RecordSource = sent
Adodc1.Refresh
End Sub
'Barcode
Private Sub txtID_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txtID = MSComm1.Input 'Recoge datos desde el lector
End If
End Sub
Cracker.py -t md5 -h e10adc3949ba59abbe56e057f20f883e -w 1234567890 -a 9 -i 3 -v
-t: Tipo de Hash
-h: Hash a Crackear
-w: Teclas a usar
-a: Maximo de Caracteres
-i: Minimo de Caracteres
-v: Modo Hacking
import sys , string , time
def main():
"Main"
title = "MD5 Cracker Brute Force"
print "\n" + title.center(45) + "\n"
def usage():
"Usage"
print "[+] Ejemplo : Cracker.py -t md5 -h e10adc3949ba59abbe56e057f20f883e -w 1234567890 -a 9 -i 3 -v"
def usagelarge():
"Usage Large"
print "\n Forma de Uso:"
print "\n [+]Ejemplo: Cracker.py -t md5 -h e10adc3949ba59abbe56e057f20f883e -w 1234567890 -a 9 -i 3 -v"
print ""
print "\t[Comandos]"
print "\t -t: Tipo de Hash"
print "\t -h: Hash a Crackear"
print "\t -w: Teclas a usar"
print "\t -a: Maximo de Caracteres"
print "\t -i: Minimo de Caracteres"
print "\t -v: Modo Hacking\n"
def timer():
"Time"
now = time.localtime(time.time())
return time.asctime(now)
if '__main__' == __name__ :
if len(sys.argv) <= 5:
main()
usagelarge()
sys.exit(1)
hhash = words = maxw = minw = typeh = ""
verbose = 0
for arg in sys.argv[1:]:
try:
if arg.lower() == "-v" or arg.lower() == "-verbose":
verbose = 1
if arg.lower() == "-h" or arg.lower() == "-hash":
hhash = sys.argv[int(sys.argv[1:].index(arg))+2]
if arg.lower() == "-a" or arg.lower() == "-max":
maxw = sys.argv[int(sys.argv[1:].index(arg))+2]
if arg.lower() == "-i" or arg.lower() == "-min":
minw = sys.argv[int(sys.argv[1:].index(arg))+2]
if arg.lower() == "-w" or arg.lower() == "-words":
words = sys.argv[int(sys.argv[1:].index(arg))+2]
if arg.lower() == "-t" or arg.lower() == "-type":
typeh = sys.argv[int(sys.argv[1:].index(arg))+2]
except(IndexError):
print "[+] Comandos Obligatorios -t(Tipo de Hash) -h(Hash) -w(Teclas) -a(Maximo de teclas) -a(Minimo de teclas)"
usage()
sys.exit(1)
if minw == "" : minw = '1'
main()
for args in (typeh, hhash, words, maxw, minw):
try:
if args != "":
if args == typeh :
if typeh.lower() != 'md5' or 'sha':
if typeh.lower() == "md5" :
typeh = '1'
print "[+] Tipo de Hash : MD5"
elif typeh.lower() == "sha" :
typeh = '2'
print "[+] Tipo de Hash : SHA1"
else:
print "[+] Tipo Invalido de Hash"
sys.exit(1)
if args == hhash :
if typeh == '1' :
if len(hhash) == 32 :
print "[+] MD5 Hash : " + hhash
else:
print "[+] Tipo Invalido de Hash"
sys.exit(1)
if typeh == '2' :
if len(hhash) == 40 :
print "[+] SHA1 Hash : " + hhash
else:
print "[+] SHA1 Invalido"
sys.exit(1)
if args == words :
print "[+] Teclas a usar : " + words
if args == maxw :
if maxw.isdigit() != False :
if int(maxw) >= 15 :
print "[+] Maximo de Digitos : 15 : " + maxw
sys.exit(1)
else:
if int(maxw) > int(minw):
print "[+] Maximo de Digitos : " + maxw
else:
print "[+] El Maximo de Digitos debe ser mayor al Minimo de Digitos"
sys.exit(1)
else:
print "[+] Maximo de Teclas = Digitos"
sys.exit(1)
if args == minw :
if minw.isdigit() != False :
if int(minw) < int(maxw) :
print "[+] Minimo de Digitos : " + minw
else:
print "[+] El minimo de Digitos debe ser menor al maximo de Digitos"
sys.exit(1)
else:
print "[+] Minimo de Teclas = Digitos"
sys.exit(1)
else:
print "[+] Comandos Obligatorios -t(Tipo de Hash) -h(Hash) -w(Teclas) -a(Maximo de teclas) -a(Minimo de teclas)"
usage()
sys.exit(1)
except(ValueError):
print "[+] Formato de comandos erroneo"
sys.exit(1)
f = open("CRACK.py",'w')
f.write("#!/usr/bin/env python\n")
if (typeh == '1') : f.write("import sys , md5 , string , time\n")
if (typeh == '2') : f.write("import sys , sha , string , time\n")
tab = '\t'
f.write("def timer():\n")
f.write(tab + "now = time.localtime(time.time())\n")
f.write(tab + "return time.asctime(now)\n")
f.write("def crackhash():\n")
i = 0 ; inwords = ""
f.write(tab + "hashh = '" + hhash.lower() +"'\n")
f.write(tab + "try:\n")
#print words
for i in words:
if i == str(words[int(len(words)-1)]) :
inwords += "'" + i + "'"
break
inwords += "'" + i + "',"
#print inwords
i = int(minw) ; iwords = "" ; a = 0
while (int(i) != int(maxw) + 1) :
for a in range(i):
if int(i) != (int(a) + 1):
iwords += "i" + str(i) + str(a) + " + "
else:
iwords += "i" + str(i) + str(a)
data = (int(a + 2) * tab + "for i" + str(i) + str(a) + " in (" + inwords + "):\n")
f.write(data)
f.write(int(i + 2) * tab + "word = '' ; value = ''\n")
f.write(int(i + 2) * tab + "word = " + iwords + "\n")
if typeh == '1' : f.write(int(i + 2) * tab + "hash = md5.new()\n")
if typeh == '2' : f.write(int(i + 2) * tab + "hash = sha.new()\n")
f.write(int(i + 2) * tab + "hash.update(str(word))\n")
f.write(int(i + 2) * tab + "value = hash.hexdigest()\n")
if verbose == 1 : f.write(int(i + 2) * tab + "print " + iwords + ' + " : " + str(value)\n')
f.write(int(i + 2) * tab + "if str(hashh) == str(value):\n")
f.write(int(i + 3) * tab + "raise Exception\n")
iwords = ""
i += 1
f.write(tab + "except(Exception):")
f.write('\n'+ 2 * tab + "print '******************** Hash Crackeado ' + 20 * '*'")
f.write('\n' + 2 * tab + "print '[+] HASH :', hashh")
f.write('\n' + 2 * tab + "print '[+] PASS :', str(word)")
f.write('\n' + 2 * tab + "print '[+] Hora de finalizacion :', timer()")
f.write('\n' + 2 * tab + "sys.exit(1)")
f.write('\n' + tab + "except(KeyboardInterrupt):")
f.write('\n' + 2 * tab + "print '[+] Process Ended ',timer()")
f.write('\n' + 2 * tab + "sys.exit(1)")
f.write("\ncrackhash()")
f.close()
print '[+] Hora de inicio : ', timer()
import CRACK
CRACK.crackhash()
Cracker.py [HASH (MD5)] [Diccionario]
Cracker.py e10adc3949ba59abbe56e057f20f883e diccionario.txt
import md5, sys, getopt
ver= "1.0"
a=0
def run():
if len(sys.argv) == 1 or sys.argv[1]=="-h" or sys.argv[1]=="--help":
print ""
print ""
print "ANTRAX"
print "WWW.ELHACKER.NET"
print ""
print "Modo de uso: Cracker.py [HASH (MD5)] [Diccionario]"
print ""
print "Ejemplo: Cracker.py e10adc3949ba59abbe56e057f20f883e diccionario.txt"
print ""
else:
if sys.argv[1]=="-v" or sys.argv[1]=="--version":
print "Cracker version: " + ver + "\nAutor: ANTRAX"
if len(sys.argv) == 3:
md5crack(sys.argv[1],sys.argv[2],)
def md5crack(hash,word):
try:
wordlist = open(word,"r")
except IOError:
print "Diccionario: " + word + " No Existe"
sys.exit(0)
global a
for line in wordlist.xreadlines():
word= line.replace("\n","")
passw = md5.new(word)
if (hash == passw.hexdigest()):
print ""
print "Password Crackeada!"
print 'MD5: ' + passw.hexdigest() + ' ---> ' + word+''
print "BY ANTRAX"
a = 1
sys.exit(0)
if ( a == 0):
print 'Password no Encontrada en este diccionario'
wordlist.close()
def main():
run()
if __name__ == "__main__":
main()