[Ctf]md5 Cracker

Source: Internet
Author: User

Recent paragraph in the question, the urine sex

MD5 local hack

[Python] #-*-coding:utf-8-*-  Import string  import hashlib  file=open ("Hello.txt", "a")  Md5input=raw _input ("Please enter md5:\n")  md5input=md5input.lower ()  apt=string.printable[:-6]  def dfs (s,num):      m= HASHLIB.MD5 ()      m.update (s)      md5temp=m.hexdigest ()      if md5temp==md5input:          file.write ("MD5 Yes:" + md5input+ "    plaintext is:" +s+ "\ n")          File.close ()          exit ( -1)      if Len (s) ==num: return for I in      apt:          dfs (s+i,num)    myinput=10               #生成字符的位数 for  J in Range (1,myinput):      dfs ("", j)  File.close ()  

MD5 online hack

[Python] #-*-coding:utf-8-*-import urllib2 import urllib import JSON import sys from htmlparser import htmlparse      R from htmlentitydefs import entitydefs reload (SYS) sys.setdefaultencoding (' Utf-8 ') class titlehtml (Htmlparser): def __init__ (self): self.title=[] self.readingtitle= "self.myfilter=" htmlparser._       _init__ (self) def handle_starttag (self, Tag, attrs): If tag==self.myfilter:self.readingtitle=1 def handle_data (self, data): If Self.readingtitle:self.title.append (data) def Handle_end  Tag (self, tag): If Tag==self.myfilter:self.readingtitle=0 def gettile (self): return Self.title class Myhtmlparser (htmlparser): def __init__ (self): htmlparser.__init__ (self) self.i           Nputvalue = {} def handle_starttag (self, Tag, attrs): #print "Encountered the beginning of a%s tag"% tag if tag = = "InPUT ": If Len (attrs) = = 0:pass else:for (variable, value) in Attrs: If variable== "name": Self.inputvalue.setdefault (Value, ') m Yname=value if variable = = "Value": Self.inputvalue[myname]=value def htt Pget (Geturl,getdata,referer): Urldata=urllib.quote (GetData) url=geturl+urldata headers={"user-agent": "Mozil la/4.0 (compatible; MSIE 6.0; Windows NT 5.1 "," Referer ": Referer} req = Urllib2. Request (url,headers=headers) Resul=urllib2.urlopen (req). Read () return Resul def httppost (geturl,getdata,refer Erdata): Data=getdata url=geturl post_data=urllib.urlencode (data) headers={"user-agent": "Mozilla/4.0 ( Compatible MSIE 6.0; Windows NT 5.1 "," Referer ": Refererdata} req=urllib2. Request (Url,headers=headers,data=post_data) Resul=urllib2.urlopen (req). Read () return Resul deF SOMD5 (MD5): Url= "http://www.somd5.com/somd5-index-md5.html" data={} data["Isajax"]= "2d6gbg7ktvgrzxjacdei7 PT "data[" MD5 "]=MD5 str=httppost (Url,data," ") Newsparser = titlehtml () newsparser.myfilter= ' H1 ' n          Ewsparser.feed (str) items = Newsparser.gettile () If Len (items) ==0:print "Somd5 not Found" else: Print "Somd5 found:" +items[0] def CMD5 (MD5): Data= "" Res=httpget ("http://www.cmd5.com/", Data, "") Viewstau T=myhtmlparser () viewstaut.feed (res) post_data=viewstaut.inputvalue post_data["Ctl00$contentplaceholder1$te Xtboxinput "]=md5 post_data[" __eventtarget "]=" "post_data[" Ctl00$contentplaceholder1$inputhashtype "]=" MD5 "p ost_data["Ctl00$contentplaceholder1$hiddenfield1"]= "0" finres=httppost ("http://www.cmd5.com/", Post_data, "http:/ /www.cmd5.com/") Newsparser = titlehtml () newsparser.myfilter= ' span ' newsparser.feed (finres) items = n Ewsparser.gettile () if LeN (items) ==0:print "Cmd5 not Found" Else:print "Cmd5 Found:" +items[3] def HKC5 (MD5): url= "/http/ Md5.hkc5.com//index.asp?action=look "data={} data[" Look "]=" Query "data[" Md5text "]=md5 str=httppost (Url,da TA, "http://md5.hkc5.com/index.asp") Finres=myhtmlparser () finres.feed (str) Mingwen=finres.inputvalue t Ry:print "Hkc5 found:" +mingwen["RR2"] except:print "Hkc5 not Found" def xx95 (MD5): Data= "" Re S=httpget ("http://md5.xx95.net/default.html", Data, "") Viewstaut=myhtmlparser () viewstaut.feed (res) Post_dat A=viewstaut.inputvalue for Key,value in Post_data.items (): If post_data[key]== "\xe8\xaf\xb7\xe8\xbe\x93\xe5\              X85\xa5md5\xe6\x88\x96\xe8\xa6\x81\xe5\x8a\xa0\xe5\xaf\x86\xe7\x9a\x84\xe5\xad\x97\xe7\xac\xa6\xe4\xb8\xb2 ": Post_data[key]=md5 finres=httppost ("http://md5.tellyou.top/default.html", Post_data, "http://md5.tellyou.top/ Default.html ") Newsparser = titlehtml () newsparser.myfilter= ' span ' newsparser.feed (finres) items = Newsparser.gettile () Try:       Print "md5.tellyou MD5 query results:" +items[0] except:print "md5.tellyou query results: No, try other similar websites" def MD5 (Syue): Finstr=httpget ("Http://md5.syue.com/ShowMD5Info.asp?      Gettype=showinfo&md5_str= ", MD5," http://md5.syue.com/") Newsparser = titlehtml () newsparser.myfilter= ' span ' Newsparser.feed (finstr) items = Newsparser.gettile () try:print Md5.syue query Results (garbled proof not found): "MD5       [0] Except:print "Md5.syue not Found" def PMD5 (MD5): Data= "" Res=httpget ("http://pmd5.com/", Data, "")      Viewstaut=myhtmlparser () viewstaut.feed (res) post_data=viewstaut.inputvalue post_data["key"]=md5 Finres=httppost ("http://pmd5.com/", Post_data, "http://pmd5.com/") Newsparser = titlehtml () newsparser.myfilter= ' Em ' Newsparser.feed (finres) items = Newsparser.gettile () try:print "PMD5 MD5 find Result:" +items[1] except:print "Pmd5 not Found" def WMD5 (MD5): Url= "HTTP://WWW.WMD5.COM/AJAX.P HP "data={} data[" Miwen "]=md5 data[" action "]=" Md5show "Finstr=httppost (Url,data," http://www.wmd5.com/" ) D1=json.    Jsondecoder (). Decode (FINSTR) try:print "WMD5 query results are:" +d1[' Md5text '] except:print "wmd5 not Found" def HEIMD5 (MD5): Url= "http://121.42.198.24//php/md5.php" data={} data["key"]=md5 finstr=httppost (URL , data, "http://121.42.198.24/php/md5.php") print "121.42.198.24 The result is:" +finstr #def XMD5 (MD5): If __name__== ' _       _main__ ': md5=sys.argv[1] #print MD5 #md5 = "d8b521d9c8591a897704b83d18ec988d" SOMD5 (MD5) HKC5 (MD5)   XX95 (MD5) Syue (MD5) PMD5 (MD5) WMD5 (MD5) HEIMD5 (MD5) CMD5 (MD5)

  

Before using the GUI version, but not this is quite easy to use, you can first run with this, mainly the CTF question not networking, put some tips, poor up dictionary, haha

[Ctf]md5 Cracker

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.