Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Senior Coder missing-score's Avatar
    Join Date
    Jan 2003
    Location
    UK
    Posts
    2,194
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Discussion: Will an md5 Value ever repeat?

    Ok, this is something that I have thought about before, and never really thought about any more until the other day.

    If you use md5 to encrypt information, you get your md5 value returned... great... but are there any limits to the number of different inputs that can be encrypted with md5.

    Basically, if enough combinations of md5 values were encrypted, would you eventually hit a repeat? (im talking alot).

  • #2
    Senior Coder missing-score's Avatar
    Join Date
    Jan 2003
    Location
    UK
    Posts
    2,194
    Thanks
    0
    Thanked 0 Times in 0 Posts
    As input for this, I am going to say that "yes", it will repeat eventually... becuase with the limit of characters used for md5, there is more possible input combinations that could be used, and therefore, a repeat could be achieved...

    Also, if anyone knows of any written resource regarding this, please do post it up.

  • #3
    Regular Coder
    Join Date
    Jun 2002
    Location
    Depends on the time of year
    Posts
    478
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Also the MD5 function in the php by default (not sure if there's anothe option) is 32 characters long, whereas the original hash spits out 64.

    The character range is a-f and 0-9.

    To get more information on how the hash was designed, you can look it up on the MIT website under the guy who wrote it, I believe it was Ron Livest.

  • #4
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,073
    Thanks
    11
    Thanked 98 Times in 96 Posts
    interesting reading at http://www.woodmann.com/crackz/Tutorials/Md5info.htm


    Consider the following, however. The MD5 creates a numeric representation of the contents of a message and displays it as a 16 character hexadecimal value. Theoretically, there are 2^128 possible MD5 hash values. Therefore, if you have a file system with 2^128+1 different files on it I can guarantee you that there are at least two different files that will generate duplicate hash values.

    Consider the reality of 2^128 possibilities. There are actually 3.402 x 10^38 or 340 billion billion billion billion or a little more than 1/3 of a googol possibilities. When you consider that most people have never seen a million of anything the actual number becomes really difficult to conceptualize. (Leave it to my nine year old to teach me that a googol, which really exists, is actually 10^100.)
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •