Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Visual Basic]Text to MD5[Tutorial]
#1
This will teach you how to make a program that converts text to an MD5 Hash


Anything in Pink In my tutorial is important...

Step One(The GUI)
This part is simple. Just make the GUI Look similar to mine and move on to the next step(Step Two)



Step Two

Step Two will be coding the Convert Button.Double click it and input this code...
Code:
textbox2.text = StringToMD5(textbox1.Text)
Under the End Sub, put this code in...
Code:
Private Function StringToMD5(ByVal Content As String) As String

You should Have This code...
Code:
Public Class Form1

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        TextBox1.Text = StringToMD5(TextBox2.Text)
    End Sub
    Private Function StringToMD5(ByVal Content As String) As String
End Class


Step Three

Under Your private function, use this code...
Code:
Dim M5 As New Security.Cryptography.MD5CryptoServiceProvider

        Dim ByteString() As Byte = System.Text.Encoding.ASCII.GetBytes(Content)
        ByteString = M5.ComputeHash(ByteString)

        Dim FinalString As String = Nothing
        For Each bt As Byte In ByteString
            FinalString &= bt.ToString("x2")
        Next
        Return FinalString
    End Function

Final Code



You are done, Test is by using the word hi.
It should look like this


[Image: 9be6c8d36c006d51ce24891f315d5e3a.png]
[Image: iddyEs.png]
Reply
#2
So how can we un-ecrypt the MD5? :-/ ?
Reply
#3
(06-20-2011, 09:07 PM)Cod3ing Wrote: So how can we un-ecrypt the MD5? :-/ ?
That would be called bruteforcing.

[Image: iddyEs.png]
Reply
#4
Thanks for share .
[Image: 0b0033.gif]
Reply
#5
Nice tutorial dude, I like this...
Thanks for sharing!
if ( ( youAreHappy) && (youKnowIt) )

clapYourHands();
Reply
#6
Thanks For Sharing. Going to make my own and make a better GUI.
Reply
#7
But i see one error in vb 2010
[Image: 0b0033.gif]
Reply
#8
(06-22-2011, 05:04 AM)reloaded Wrote: But i see one error in vb 2010
What error?

C + P it and post it as a response.

[Image: iddyEs.png]
Reply
#9
(06-20-2011, 09:07 PM)Cod3ing Wrote: So how can we un-ecrypt the MD5? :-/ ?

It's not encrypted, it's hashed. Since hashing is a one way process, it is impossible to get the original value from the hash.
Reply
#10
you forgot the end class statement in the final code

but otherwise good job
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  How To make an advanced Operating System in Visual Basic 2010 ? Mohamed Samir 9 12,442 01-15-2013, 09:30 PM
Last Post: Resistance
  [TUT] MD5 Encrypter & Finder [VB.NET] Fragma 12 7,857 11-25-2012, 10:36 PM
Last Post: ƃu∀ ıʞƃu∀
  [TuToRiAl] How to make Offline (No Internet) Captcha (Human Confirmation) [TuToRiAl] Resistance 24 12,529 08-30-2012, 10:14 PM
Last Post: Resistance
  [Visual Basic] FTP Uploader [Tutorial] Coding Support 6 3,010 08-12-2012, 12:36 AM
Last Post: Kenneth
  Visual Studio Bill Nye The Science Guy 1 1,029 03-19-2012, 09:08 AM
Last Post: BreShiE

Forum Jump:


Users browsing this thread: 3 Guest(s)