User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the PHP section within the Web Development category of DaniWeb, a massive community of 373,375 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,732 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our PHP advertiser: Lunarpages PHP Web Hosting
Views: 249 | Replies: 2 | Solved
Reply
Join Date: Mar 2007
Location: RI
Posts: 146
Reputation: Dsiembab is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 1
Dsiembab's Avatar
Dsiembab Dsiembab is offline Offline
Junior Poster

md5 superhashing

  #1  
Mar 20th, 2008
I like to read about hashing passwords and have read articles about how md5 and sha-1 could be deciphered albiet it would take 25 million dollar computer and time but still if you could take a password and split it into two pieces and md5 hashed the two pieces add a salt in between and bring the two pieces togethter and md5 hash that i.e.
<?php
$password = $_POST['password'];
$length=strlen($password);
$divide=round($length/2);
$pass=str_split($password, $divide);
$salt ="097ever";
$pass1=md5($pass[0]);
$pass2=md5($pass[1]);
$newpass=md5($pass1.$salt.$pass2);
?>
this might add a half hour to your 25 million dollar computer.
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Mar 2008
Posts: 153
Reputation: Suomedia is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 19
Suomedia Suomedia is offline Offline
Junior Poster

Re: md5 superhashing

  #2  
Mar 21st, 2008
It is said that if you could sit a monkey in front of a typewriter for long enough it would eventually type out the Lord's prayer.....


Matti Ressler
Suomedia
If you want your dreams to come true, the first thing you must do is to wake up....
Suomedia - Dynamic Content Management
Reply With Quote  
Join Date: Mar 2007
Location: RI
Posts: 146
Reputation: Dsiembab is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 1
Dsiembab's Avatar
Dsiembab Dsiembab is offline Offline
Junior Poster

Re: md5 supersalting

  #3  
Mar 21st, 2008
so if I used an array instead like this
<?php
$password = $_POST['password'];
$length=strlen($password);
$divide=round($length/2);
$pass=str_split($password, $divide);
$salt =array(b,o,n,k,y,w,l,e,m);
$saltydog=array_pop($salt);
$pass1=md5($pass[0]);
$pass2=md5($pass[1]);
$newpass=md5($pass1.$salt[0].$salt[6].$salt[1].$salt[5].$saltydog.$salt[6].$saltydog.$salt[1].$salt[2].$salt[3].$salt[7].$salt[4].$pass2);
?> 
does that make more sense richard?
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb PHP Marketplace
Thread Tools Display Modes

Other Threads in the PHP Forum

All times are GMT -4. The time now is 3:08 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC