Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[TUT] MD5 Encrypter & Finder [VB.NET]
#1
In this tutorial I will guide you through making your own MD5 Encrypter & Finder.

MD5 Encrypter will Encrypt plain text into MD5 Hash.

MD5 Finder will search through 3 online databases for the desired hash and show the results in plain text.

Screenshots of what your program might look like:
[Image: md52.jpg]
[Image: md5.jpg]

Ok we will start with the MD5 Encrypter.

First off add the function:
Code:
Function MD5Hash(ByVal strToHash As String) As String
        Dim md5Obj As New Security.Cryptography.MD5CryptoServiceProvider
        Dim bytes() As Byte = System.Text.Encoding.ASCII.GetBytes(strToHash)
        bytes = md5Obj.ComputeHash(bytes)
        Dim strResult As String = ""
        For Each b As Byte In bytes
            strResult += b.ToString("x2")
        Next
        Return strResult
    End Function

Now for Button1_click (Encrypt button) You need to add this code:
Code:
TextBox1.Text = MD5Hash(TextBox1.Text)

In the example above i have added a Copy text button. Here is the code for that if you wish to add it:
Code:
TextBox1.SelectAll()
TextBox1.Copy()

For button3_click add:
Code:
Form2.show()

Ok now for the MD5 Finder..

First off i will list the names for each object otherwise you might get confused...

Timer1 = md5c
Timer2 = checkHost
Timer3 = gdata
Timer4 = passcrack
Textbox = txtHash
listView = listView

You need the following Imports:
Code:
Imports System
Imports System.Web

Declare the following web browsers:
Code:
Dim webbrowser As New WebBrowser
Dim gdatabrow As New WebBrowser
Dim passcracking As New WebBrowser

In Form2_load add this code:
Code:
loadList()

        button1.Text = "Wait.."
        button1.Enabled = False
        checkHost.Start()
        webbrowser.Navigate("http://www.md5crack.com")
        gdatabrow.Navigate("http://gdataonline.com/seekhash.php")
        passcracking.Navigate("http://www.passcracking.com/index.php")

Ok now the following bits of code act like a bot on each site.
Code:
Private Sub md5crack()
webbrowser.Document.GetElementById("term").SetAttribute("value", Trim(txtHash.Text))
        webbrowser.Document.GetElementById("crackbtn").InvokeMember("click")
md5c.Start()
End Sub

Code:
Private Sub gdataonline()
        gdatabrow.Document.GetElementById("hash").SetAttribute("value", Trim(txtHash.Text))
        gdatabrow.Document.Forms(0).InvokeMember("submit")
        gdata.Start()
    End Sub

Code:
Private Sub pcracking()
        passcracking.Document.GetElementById("datafromuser").SetAttribute("value", Trim(txtHash.Text))
        passcracking.Document.Forms(0).InvokeMember("submit")
        passcrack.Start()
    End Sub

Ok now the rest is what gets all the information & puts it in the Listview

For md5c_tick:

Code:
If webbrowser.Document.Body.InnerText.Contains("Your Results") Then

            Dim t2find As New System.Text.RegularExpressions.Regex("\("".*""\)")
            Dim storage As String = Me.webbrowser.Document.Body.InnerText
            Dim result As String = t2find.Match(storage).Value
            Dim reslen As Integer = result.Length

            If String.IsNullOrEmpty(result) Then

                ListView.Items(0).SubItems.Add("Not Found")
            Else
                Dim pText As String = result.Substring(2, reslen - 4)
                ListView.Items(0).SubItems.Add(pText)
            End If
            md5c.Stop()
            webbrowser.Navigate("http://www.md5crack.com")

        End If

For button1_click:
Code:
loadList()

        checkHost.Start()

        md5crack()
        gdataonline()
        pcracking()

For checkHost_tick:
Code:
If webbrowser.ReadyState = WebBrowserReadyState.Complete AndAlso gdatabrow.ReadyState = WebBrowserReadyState.Complete AndAlso passcracking.ReadyState = WebBrowserReadyState.Complete Then
            'If passcracking.ReadyState = WebBrowserReadyState.Complete Then
            System.Threading.Thread.Sleep(2000)
            txtHash.Text = ""
            txtHash.ReadOnly = False
            look.Text = "Crack"

            look.Enabled = True
            checkHost.Stop()
        End If

For gdata_tick:
Code:
If gdatabrow.Document.Body.InnerText.Contains("RESULTS:") Then

            Dim t2find As New System.Text.RegularExpressions.Regex(txtHash.Text & ".*\s")
            Dim storage As String = Me.gdatabrow.Document.Body.InnerText
            Dim result As String = t2find.Match(storage).Value
            Dim reslen As Integer = result.Length

            Dim pText As String = result.Substring(32, reslen - 32)
            If pText.Contains("?????") Then
                ListView.Items(1).SubItems.Add("Not Found")
            Else
                ListView.Items(1).SubItems.Add(pText)
            End If


            gdata.Stop()
            gdatabrow.Navigate("http://gdataonline.com/seekhash.php")

        End If

For passcrack_tick:
Code:
If passcracking.Document.Body.InnerText.Contains(txtHash.Text) Then

            Dim t2find As New System.Text.RegularExpressions.Regex("<TD\sbgColor=#ff0000>.*<\/TD>")
            Dim storage As String = passcracking.Document.Body.InnerHtml
            Dim result As String = t2find.Match(storage).Value
            Dim reslen As Integer = result.Length



            If String.IsNullOrEmpty(result) Then
                ListView.Items(2).SubItems.Add("Not Found")
            Else
                Dim pText As String = result.Substring(20, reslen - 25)
                ListView.Items(2).SubItems.Add(pText)
            End If
            passcrack.Stop()
            passcracking.Navigate("http://www.passcracking.com/index.php")

        End If

Now all there is to do is the coding for loadlist which is:
Code:
Private Sub loadList()
ListView.Clear()
        ListView.Columns.Add("Website").Width = 100
        ListView.Columns.Add("Result").Width = 156

        ListView.Items.Add("md5crack")
        ListView.Items.Add("gdataonline")
        ListView.Items.Add("passcracking")
end sub

And finally to dispose of the webbrowsers once the form closes:
Code:
Private Sub Form1_FormClosing(ByVal sender As System.Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles MyBase.FormClosing
   webbrowser.Dispose()
   gdatabrow.Dispose()
   passcracking.Dispose()
end sub

And thats everything! If I've made any mistakes please let me know.

Credits for the Finder go to whoever released it on Leetcoders.

Enjoy.
Reply
#2
Useful code, thanks for this dude !
Reply
#3
Glad someone liked it. Smile
Reply
#4
You have many skills. Smile
Reply
#5
Thanks for this DubStep Tongue , useful. And good job
[Image: 6fp9it.png]
Reply
#6
I tested and it works, thanks again :p
Reply
#7
Glad you guys like it. If you need any help with anything just ask.
Reply
#8
Thank's for this share..i will try to make this in future!
[Image: logo.png]
xSexy.org | The New Sexy Forum ! [Erotic Pics & Videos]
Reply
#9
This isn't teaching! It's copy and pasting!
Maybe your should go into a little further details explaining what certain functions and codes actually do, instead of saying "Now for Button1_click (Encrypt button) You need to add this code:"
Reply
#10
This is cool one, thanks friend.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How to hook the keyboard. [VB.NET] [TuT] Vorfin 92 60,887 09-23-2019, 11:55 AM
Last Post: Jamimartin
  VB.NET Port Scanner [TUT] Fragma 30 14,433 11-27-2012, 11:26 PM
Last Post: ƃu∀ ıʞƃu∀
  [TUT] How to make a simple WebBrowser in VB 2010! [TUT] - [ Pictures] Statics 95 61,762 10-07-2012, 06:56 AM
Last Post: a99
  [HELP][VB6] Comparing md5/file size? Cloud203 5 2,418 02-04-2012, 02:47 PM
Last Post: Denny Crane
  [TUT]Auto-Update System[TUT] HB Virus 3 2,425 01-07-2012, 02:21 PM
Last Post: Mastermrz

Forum Jump:


Users browsing this thread: 3 Guest(s)