Results 1 to 4 of 4

Thread: [RESOLVED] MD5 Encryption - Un-encrypting it

  1. #1

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Resolved [RESOLVED] MD5 Encryption - Un-encrypting it

    Hello. I have some info in a table that is MD5 encryped. How do i display the info from the table so that it displays regularly? I tried this:
    PHP Code:
    <? include("includes/conn.php"); ?>
    <?php 
                
    //build our query 
        
    $query "SELECT * FROM `members` WHERE member_id=151 LIMIT 1"
        
    $query mysql_query($query) or die(mysql_error()); 
        
    //loop through each record 
        
    while($array mysql_fetch_array($query)) { 
                
    //print out the field values and values using print_r 
                
    print_r($array['member_email']."<br>"); 
                
    $password $array['member_password'];
                echo 
    MD5($password);
                 }
    ?>
    and that just displayed it with the encryption...
    My usual boring signature: Something

  2. #2
    PowerPoster sunburnt's Avatar
    Join Date
    Feb 2001
    Location
    Boulder, Colorado
    Posts
    1,403

    Re: MD5 Encryption - Un-encrypting it

    MD5 is a hash algorithm, not an encryption algorithm.

    When you take the MD5 sum of data, it gives you a (reasonably) unique value. You can then take the MD5 of some other piece of data. If both the MD5 sums are the same, the data is the same.

    You don't "unhash" or decrypt an MD5 sum. It's impossible; a hash is a one-way operation.
    Every passing hour brings the Solar System forty-three thousand miles closer to Globular Cluster M13 in Hercules -- and still there are some misfits who insist that there is no such thing as progress.

  3. #3

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: MD5 Encryption - Un-encrypting it

    so there is no way to read the 'hash' regularly?
    My usual boring signature: Something

  4. #4
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594

    Re: [RESOLVED] MD5 Encryption - Un-encrypting it

    No. The whole point of a hash is that it's non-reversible and non-imitable.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

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



Click Here to Expand Forum to Full Width