MD5 shuffling with a defined pattern of numbers I've created a MD5 shuffler with a defined number pattern.  Does this make sense?  Will this make storing passwords more secure?  Is it efficient?

    &lt;?php
echo "&lt;pre&gt;";
$md5 = "e2fc714c4727ee9395f324cd2e7f331f";
echo "Old hash: " . $md5 . "&lt;br /&gt;";
$hash = str_split($md5, 1);
$shuffle = explode(",", "24,29,21,23,2,30,10,22,6,28,26,11,8,19,9,20,16,3,0,14,18,15,12,25,5,4,31,1,7,27,13,17");
$newhash = "";
for ($i = 0; $i &lt; 32; $i++) {
$s = $shuffle[$i];
$newhash .= $hash[$s];
}
echo "New Hash: " . $newhash . "&lt;br /&gt;";
$newhash = str_split($newhash, 1);
$reverse = "";
for ($i = 0; $i &lt; 32; $i++) {
$s = $shuffle[$i];
$reverse[$s]= $newhash[$i];
}
ksort($reverse);
$reversehash = "";
foreach ($reverse as $value) {
$reversehash .= $value;
}
echo"Reversed hash: " . $reversehash . "&lt;br /&gt;";
echo "&lt;/pre&gt;";
?&gt;
Will this make storing passwords more secure?


Using MD5 for passwords is a bad idea, not because of its cryptographic weaknesses, but because it's fast. This means that an attacker can try billions of candidate passwords per second on a single GPU.

I wouldn't even bother creating my own secure hashing functions if I'm not an expert at it. There are libraries out from people who have already done all the hard work for you and have tested them thoroughly for security. PHPass is one of them.

Matter of fact, if you run PHP 5.5 or greater, you can use its native function: password_hash().