[VB.Net]MD5 Encrypter

Page 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    [VB.Net]MD5 Encrypter

    Very simple, it just runs a timer with an interval of 10ms and auto updates as you type, anything typed into the first text box shows up in the second textbox in md5 encryption.

    This is very basic but i use it when adding user accounts to a database so i dont have to go on a web based one where they load it into a database.

    Screen shot:


    Download:
    http://default.site40.net/release/md5.zip

    Source:
    Form1.vb
    Code:
    Imports System.Security.Cryptography
    Imports System.Text
    
    Public Class Form1
    
        Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
            TextBox2.Text = MD5(TextBox1.Text)
            Timer1.Interval = "10"
            Timer1.Start()
        End Sub
    
        Public Function MD5(ByVal Source) As String
            Dim Bytes() As Byte = ASCIIEncoding.ASCII.GetBytes(Source)
            Dim MD5H As New MD5CryptoServiceProvider
            Dim Byt() As Byte = MD5H.ComputeHash(Bytes)
            Dim i As Integer = (Byt.Length * 2 + (Byt.Length / 8))
            Dim StrBuild As StringBuilder = New StringBuilder(i)
            Dim i2 As Integer
            For i2 = 0 To Byt.Length - 1
                StrBuild.Append(BitConverter.ToString(Byt, i2, 1))
            Next i2
            Return StrBuild.ToString().TrimEnd(New Char() {" "c}).ToLower
        End Function
    
        Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
            TextBox2.Text = MD5(TextBox1.Text)
        End Sub
    
        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            Clipboard.SetDataObject(Me.TextBox2.SelectedText)
            Me.TextBox2.SelectAll()
            Me.TextBox2.Copy()
        End Sub
    End Class


  2. #2
    swagggggg Livar is offline
    MemberRank
    Oct 2008 Join Date
    United KingdomLocation
    2,272Posts

    Re: [VB.Net]MD5 Encrypter

    Woot! Hope you could've done decryptor also

  3. #3
    Infraction Banned rice is offline
    MemberRank
    Nov 2009 Join Date
    2,905Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by PowahAlert View Post
    Woot! Hope you could've done decryptor also
    md5 is a one way, you know that right?

  4. #4
    Account Upgraded | Title Enabled! Carrino is offline
    MemberRank
    Mar 2010 Join Date
    1,114Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by Rice View Post
    md5 is a one way, you know that right?
    until someone finds out how to decrypt it.

  5. #5
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by PowahAlert View Post
    Woot! Hope you could've done decryptor also
    i lol'd

  6. #6
    Developer Chris is offline
    DeveloperRank
    Nov 2008 Join Date
    933Posts

    Re: [VB.Net]MD5 Encrypter

    Or you could make a new php file and type in

    PHP Code:
    <?php

    echo md5(your words);

    ?>
    saves all the downloading and shit...

  7. #7
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    Re: [VB.Net]MD5 Encrypter

    yeah but then u have to edit the php file every time u want to encrypt a new word

  8. #8
    :-) s-p-n is offline
    DeveloperRank
    Jun 2007 Join Date
    Next DoorLocation
    2,098Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by viper67 View Post
    yeah but then u have to edit the php file every time u want to encrypt a new word
    PHP Code:
    <?php
    if(isset($_GET['text']))
    {
        
    $md5 md5($_GET['text']);
        
    $_GET['text'] = htmlspecialchars($_GET['text']);
        echo 
    $_GET['text'] . ' ~>MD5~> ' $md5;
    } else {
        
    $_GET['text'] = 'String to convert to MD5';
    }
    echo 
    '<form action="" method="get">
    <input type="text" name="text" value="'
    .$_GET['text'].'" />
    <input type="submit" name="convert" value="Convert to MD5" />
    </form>'
    ;
    myfile.php?text=Hello, World
    Last edited by s-p-n; 22-01-11 at 11:04 PM.

  9. #9
    Developer Chris is offline
    DeveloperRank
    Nov 2008 Join Date
    933Posts

    Re: [VB.Net]MD5 Encrypter

    Good job on the project, but it's pretty pointless.

  10. #10
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    Re: [VB.Net]MD5 Encrypter

    well its not pointless for me :]

    Thanks for the comments though, criticism is always welcome :]

  11. #11
    Ginger by design. jMerliN is offline
    MemberRank
    Feb 2007 Join Date
    2,497Posts

    Re: [VB.Net]MD5 Encrypter

    ......................

    Fine.. I'll just leave this here to show how stupid this is....

    HOLY SHIT, ITS MD5!!!

  12. #12
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    Re: [VB.Net]MD5 Encrypter

    again, at least i dont have to open the website, this sits on my desktop, you can call it pointless all you want but it works for me.

  13. #13
    Ginger by design. jMerliN is offline
    MemberRank
    Feb 2007 Join Date
    2,497Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by viper67 View Post
    again, at least i dont have to open the website, this sits on my desktop, you can call it pointless all you want but it works for me.
    You seem to be afraid of tabbed browsing. It's convenient yo.

    And there's no reason you should be calculating MD5s by hand. You're doing something wrong.

  14. #14
    Ω -DefaulT is offline
    MemberRank
    Aug 2006 Join Date
    Emerald CityLocation
    1,429Posts

    Re: [VB.Net]MD5 Encrypter

    nah, i am working on a server emulator, and rather then make a php scirpt to create new accounts for my testers i just add them to the db manually, so i need the md5 for there passwords, this is just easier for me.

  15. #15
    Ginger by design. jMerliN is offline
    MemberRank
    Feb 2007 Join Date
    2,497Posts

    Re: [VB.Net]MD5 Encrypter

    Quote Originally Posted by viper67 View Post
    nah, i am working on a server emulator, and rather then make a php scirpt to create new accounts for my testers i just add them to the db manually, so i need the md5 for there passwords, this is just easier for me.
    See, you're doing it wrong.

    Both MySQL (MySQL :: MySQL 5.5 Reference Manual :: 11.13 Encryption and Compression Functions) and MSSQL (HASHBYTES (Transact-SQL)) can calculate MD5s for you.

    Stop being noob, thx.



Page 1 of 2 12 LastLast

Advertisement